Open martinheidegger opened 7 years ago
Is it troublesome to use isomorphic-fetch as a dependent module ?
It should be part of the dependencies in the package.json
. Using isomorphic-fetch
without specified dependencies is not enough.
It's a dilemma. I also thought so in the early stages of development. However, recently fetch has already been implemented in modern browsers. Those browsers do not need the bundled fetch module in the library. So I did not include fetch module in package.json.
A polyfill needs to be available anyhow (since not all browsers implement it) and you could make a separate "no-fetch.js" that can be deeplinked using require('backlog-js/no-fetch')
.
you could make a separate "no-fetch.js" that can be deeplinked using require('backlog-js/no-fetch').
I see. That is a good idea. In the near future I will try to add that split implementation to this library. Thank you for a good suggestion 😄
fetch
as used in src/request.ts#L54 is not part of the common nodejs runtime and returns in an error (making it difficult to use the backlog api)