Skip to content

Commit

Permalink
bumping versions and adding react 18 to the supported peer deps.
Browse files Browse the repository at this point in the history
  • Loading branch information
sheaivey committed Jun 4, 2022
1 parent 195a042 commit b0097ff
Show file tree
Hide file tree
Showing 6 changed files with 11,249 additions and 754 deletions.
12 changes: 6 additions & 6 deletions examples/advanced/app.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Request } from 'react-axios'
import React from 'react'
import ReactDOM from 'react-dom'
import { createRoot } from 'react-dom/client'

class App extends React.Component {
constructor(props) {
Expand Down Expand Up @@ -79,10 +79,10 @@ class App extends React.Component {
}
}


ReactDOM.render(
const container = document.getElementById('app')
const root = createRoot(container)
root.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('app')
<App />
</React.StrictMode>
)
11 changes: 6 additions & 5 deletions examples/provider/app.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { AxiosProvider, Get } from 'react-axios'
import axios from 'axios'
import React from 'react'
import ReactDOM from 'react-dom'
import { createRoot } from 'react-dom/client'

const axiosProvider = axios.create({
baseURL: '/api/provider/',
Expand Down Expand Up @@ -57,9 +57,10 @@ class App extends React.Component {
}
}

ReactDOM.render(
const container = document.getElementById('app')
const root = createRoot(container)
root.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('app')
<App />
</React.StrictMode>
)
12 changes: 6 additions & 6 deletions examples/request/app.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Request, Get, Post, Put, Delete, Head, Patch } from 'react-axios'
import React from 'react'
import ReactDOM from 'react-dom'
import { createRoot } from 'react-dom/client'

class App extends React.Component {
constructor(props) {
Expand Down Expand Up @@ -57,10 +57,10 @@ class App extends React.Component {
}
}


ReactDOM.render(
const container = document.getElementById('app')
const root = createRoot(container)
root.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('app')
<App />
</React.StrictMode>
)
13 changes: 7 additions & 6 deletions examples/withAxios/app.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { withAxios } from 'react-axios'
import React from 'react'
import ReactDOM from 'react-dom'
import { createRoot } from 'react-dom/client'

class App extends React.Component {
render() {
Expand Down Expand Up @@ -46,9 +46,10 @@ const DemoComponentHoC = withAxios({
url: '/api/request',
})(DemoComponent)

ReactDOM.render(
const container = document.getElementById('app')
const root = createRoot(container)
root.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('app')
)
<App />
</React.StrictMode>
)
Loading

0 comments on commit b0097ff

Please sign in to comment.