@easy-uniapp/api
v1.0.8
Published
Easy Uni-App Api
Downloads
17
Maintainers
Readme
Welcome to @easy-uniapp/api 👋
Easy Uni-App Api
🏠 Homepage
Install
# yarn
yarn add @easy-uniapp/api
# npm
npm install @easy-uniapp/api --saveUsage
import api from '@easy-uniapp/api'
const api = new Api()
const isDev = process.env.NODE_ENV === 'development'
const baseUrl = isDev ? '[developmentServer]' : '[productServer]'
api.setConfig({
baseUrl,
beforeRequest: async (requestOptions) => {
// do something...
},
beforeResponse: async (ret) => {
// do something...
},
})
export default apiAuthor
👤 godtail [email protected]
- Github: @easy-uniapp
🤝 Contributing
Contributions, issues and feature requests are welcome!
Feel free to check issues page. You can also take a look at the contributing guide.
Show your support
Give a ⭐️ if this project helped you!
📝 License
Copyright © 2020 godtail [email protected].
This project is MIT licensed.
This README was generated with ❤️ by readme-md-generator
