Search code examples
firebasefirebase-hostingjson-server

Firebase and json-server


I'm currently using json-server repo to emulate my back-end db and server for a prototype. To use/start json-server, I need to execute npm run json:server.

I've deployed my project to firebase but can't find a way to access a cmd or run that command from my own git-bash.

Is there any way of doing so or firebase doesn't allow to run commands on their end?


Solution

  • If you want to run small Node.js snippets on Firebase, have a look at the integration between Firebase Hosting and Cloud Functions.

    Also see the Firebase documentation on what can you host on Firebase? and the overview documentation for running micro-services on Firebase Hosting and Cloud Functions.