Often times it is useful to use a system-wide .npmrc file to authenticate to private repositories. However when working with development containers in VS Code you lose this context as the container is, of course, fully isolated.

However you can actually mount your global .npmrc file inside your container with some clever configuration inside your devcontainer.json file.

Using the mounts configuration, it is possible to attach the system-wide .npmrc file to your container as a docker volume. This way your development container will be able to use your previously authenticated npm repositories. Awesome!


Let’s say you have a GraphQL API and now you want to start accepting file uploads. This is possible using the following the Upload Scalar type from graphql-upload, as detailed here https://www.apollographql.com/docs/apollo-server/data/file-uploads/ (keep in mind you will need to use the graphql-multipart-request-spec to actually upload files, as explained here https://github.com/jaydenseric/graphql-multipart-request-spec)


Recently I have started exploring the NoSQL solution called Fauna to integrate it with one of my side projects. It took some digging and exploring to get it set-up and well integrated with my intended set-up, but I now have a solid set-up for future Next.js/Fauna projects. …

Liam Martens

Developer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store