I would like Azurite to be requirable in Node.js so that I can run it as a part of other scripts.
Being "Based on Node.js" and distributed on npm, I expected this to be the case (I'm really not trying to sound entitled here). The current solution doesn't feel very good, and it would be very nice to have an official JavaScript API to more easily be able to run Azurite with other services (I'm currently using Azure Functions Core Tools, Azurite, Browsersync, and Webpack together to develop Azure Functions locally).
First: thanks for this project. It works extremely well for all my purposes (except one).
Which service(blob, file, queue, table) does this issue concern?
All services
Which version of the Azurite was used?
3.8.0
Where do you get Azurite? (npm, DockerHub, NuGet, Visual Studio Code Extension)
npm
What's the Node.js version?
12.18.0
What problem was encountered?
Can not require Azurite in a Node.js context.
Steps to reproduce the issue?
Create a file
azurite-require.js
with the following content.Run the file with
node
.Observe the error message.
Have you found a mitigation/solution?
Yes, but it's not very ergonomic. This is a stripped down version of what I currently use.
Wanted behavior
I would like Azurite to be requirable in Node.js so that I can run it as a part of other scripts.
Being "Based on Node.js" and distributed on npm, I expected this to be the case (I'm really not trying to sound entitled here). The current solution doesn't feel very good, and it would be very nice to have an official JavaScript API to more easily be able to run Azurite with other services (I'm currently using Azure Functions Core Tools, Azurite, Browsersync, and Webpack together to develop Azure Functions locally).