refactor: use fetch api instead of axios

This commit is contained in:
SukkaW
2021-09-04 12:15:30 +08:00
committed by 神戸小鳥
parent 0cee643697
commit dbac251c76
2 changed files with 1 additions and 2 deletions

View File

@@ -1,7 +1,7 @@
import App from '../src/app.js';
window.json = async fileName=>(await axios(`../data/${fileName}.json`)).data;
window.json = async fileName => await (await fetch(`../data/${fileName}.json`)).json();
// Pssst, I've created a github package - https://github.com/brookesb91/dismissible
const hideBanners = (e) => {