I'm not a Webpack expert, so this might be the wrong way to look at the problem, but that's what I want to find out:
I'm developing a package/Webpack plugin that creates some JSON files that can be referenced in the application. Think the following:
.
├── package.json
└── src
├── index.ts
├── somefolder/
│ └── somefile.ts
└── resources/
├── resource1.json
└── resource2.json
Now the tricky part is that I want load those resources(resource1.JSON
and resource2.JSON
) from an API of some sort, in development. I only want to make them into JSON files at build time.
Now my question is, how do I actually make it possible to reference the non-existant JSON files; or if that's the wrong thing to do, what should I do? Do I need to create some sort of tool that temperorily makes those files, and tell people to gitignore them?
Thanks