bukalapak/snowboard

basePath added twice before fetchJSON requests

jony89 opened this issue · 0 comments

the following line in Router.svelte :

  const jsonPath = "/__json__/";

Actually after build turns into :

  const jsonPath = "my-base-path/__json__/";

yet it is being added again in :

  const fetchJSON = async uuid => {
    const fullPath = urlJoin(config.basePath, jsonPath, `${uuid}.json`);
    const { data } = await axios.get(fullPath);

    return data;
  };

I am configuring the basePath with :

module.exports = {
  html: {
    basePath:
 }
}