updated fetch url
This commit is contained in:
+1
-2
@@ -1,7 +1,6 @@
|
||||
import React, { Component } from 'react';
|
||||
|
||||
export default class App extends Component {
|
||||
static displayName = App.name;
|
||||
|
||||
constructor(props) {
|
||||
super(props);
|
||||
@@ -52,7 +51,7 @@ export default class App extends Component {
|
||||
}
|
||||
|
||||
async populateWeatherData() {
|
||||
const response = await fetch('weatherforecast');
|
||||
const response = await fetch('https://criminalminds-server.azurewebsites.net/weatherforecast');
|
||||
const data = await response.json();
|
||||
this.setState({ forecasts: data, loading: false });
|
||||
}
|
||||
|
||||
@@ -11,7 +11,4 @@ root.render(
|
||||
</React.StrictMode>
|
||||
);
|
||||
|
||||
// If you want to start measuring performance in your app, pass a function
|
||||
// to log results (for example: reportWebVitals(console.log))
|
||||
// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
|
||||
reportWebVitals();
|
||||
|
||||
Reference in New Issue
Block a user