Skip to content

Commit

Permalink
.env
Browse files Browse the repository at this point in the history
  • Loading branch information
romiogaku committed Feb 24, 2018
1 parent d644525 commit c5e912c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
REACT_APP_AIKATSUP_API_BASE_URL="http://localhost:29903/api/"
5 changes: 4 additions & 1 deletion src/components/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import axios from "axios";
import Alert from "react-s-alert";

const instance = axios.create({
baseURL: "http://localhost:29903/api/",
baseURL: process.env.REACT_APP_AIKATSUP_API_BASE_URL,
timeout: 1000
});

Expand All @@ -18,6 +18,9 @@ class App extends React.Component {
};
}
handleSubmit(e) {
if (!this.state.word) {
return;
}
instance
.get("/v1/search", {
params: {
Expand Down

0 comments on commit c5e912c

Please sign in to comment.