Feathersjs frontend and backend in a single project - node.js

I'm looking to build a small customer management portal for myself. I've recently started working with node and vuejs a lot (coming from an html/css/javascript background). I've really enjoyed CLI development though and am looking to build a customer management portal (nothing fancy) that has a MySQL backend. After studying frameworks and ideas I found feathersjs which I REALLY like. After a few hours I was able to have a REST api that returns data from my MySQL database and uses authentication. I can get MySQL data in a JSON datasource and even do inserts, updates, deletes. I generated the services and models using the feathersjs CLI generator.
My question is, do I really need to make two separate projects (one for backend and one for a public frontend) and run them each on a node server? Or could I do this in as single project? I'm still learning and reading up on feathersjs but I'm not seeing a way to make this possible. I do see a public folder in my feathersjs project that was generated but I don't know how to utilize it for node (I wanted my frontend written in Vue). I can see how static HTMLfiles would work in this public folder.

Related

Is it ok for a NodeJs API to have both MongoDb and MySQL(with prisma), but for different purposes?

Let me explain, so, I'm building this web application that visualizes data and the dataset that I'm working with is uploaded on a mongodb cluster. I'm also planning on making a login system using prisma and mysql. Should I build a new api for the whole user part or work with both databases in the same project?

Does STRAPI helpful to develop REST api to connect Flutter app easily and cost effectively

These days, I'm developing a Car Service application using Flutter. I already developed my flutter app using mock data with json files. This is my flutter app
https://play.google.com/store/apps/details?id=com.clivekumara.srilankacarwashfinder
Now I want to develop own rest api. Basically below requirements should be handled in the rest api.
1. Image Uploding and store images
2. Mange authentications
3. Other entity crud operations
4. Location base functionalities.
For fullfill above requirements I research a backend techologies. This api sholud be faster and easy to implement. Also deployment cost sholud be less.
For that I choose StrApi CMS platform with Mongodb to develop this requirement.
Can you give me some idea that choson technologies are compatible with the requirement. What are the cost effective deployment technologies (Hosting space, Database server etc...) compatibility with this Strapi and mongodb .
I use strapi for building static websites. Its pretty easy to use and build fast API. I also saw some Flutter apps built with strapi backend and they work flawlessly. It seems to be a good choice but might be challenging sometimes specially if you are building a very complex app.
You can use Heroku for strapi hosting. They have a free plan that will be enough for development purpose. Note that Heroku does not give you space for your uploads like images. You will still need to buy some space on S3 or Digitalcean spaces or other services.
DigitalOcean has a Oneclick installation of Strapi. It costs $10/month and if you add a $5/month space to your plan then you have $15/month to start. For database Strapi comes with SQL Lite by default but you should use Postgres or MangoDB to build your project for production.

Angular with Oracle

I am trying to figure out if there is a way to build applications using Angular/ORDS/Oracle, i am new to this web stack. What i understood so far is we need one front end / back end / database to build entire application.
in general we use Angular/Nodejs/Sql Server to develop application. in this Angular is front ent/ Node js is used to build backend or web services. Sql server is the database.
Is there a good example or resource to learn how to build apps using Angular/ORDS/Oracle with one CRUD example.
With Oracle and ORDS, you'll just define some REST Services to feed data to your Angular app.
You'll hopefully be making VERY similar, GET, PUT, POST, & DELETE calls as you were doing before.
You can 'shape' the Service templates to have the mapping that you want. They are then back-ended by Oracle SQL and/or PL/SQL that runs in the database.
ORDS handles paging the results and transforming everything in and out of the database to {json}
I have lots of resources for you getting started with REST Services in Oracle here.

Connecting React and React Native with Express

So I just started learning ReactJS and React Native.
I have some knowledge of MEN (Mongo, Express, Node). Up to this point, I learned how to res.render() files and pass objects in there.
Now what I need to do, is make MERN app. This app also needs to have Android and iOS version of it.
So far I learned that R stands for ReactJS, not react-native. Is there a way so it includes both? And where do I put react files when I have folder structure like from express-generator? Or is there a way they can be in completely different directories, and one calls the other via import?
It comes down to architecture I believe. The way I like to create the stack goes as follows.
You can create an API using Mongo/Express/Node that serves endpoints for your client app (created using reactjs, react-native and whatever other tech you want to include) to call using HTML requests. This would work for both mobile apps (using react-native) and desktop apps (using reactjs).
There's a couple different ways to deploy this. You can create 2 separate apps, a server app and a client app, which are both hosted individually by 2 separate hosts. This is useful because you decouple your front end code from your back end code. Also, you can have 2 separate directories for your code.
Another method of deployment would be to have your server serve your client files. This ones a little bit tricker, but you will be able to deploy your entire app inside 1 host so this option is also cheaper. I would suggest reading this article to figure out how to implement this and the file structure https://originmaster.com/running-create-react-app-and-express-crae-on-heroku-c39a39fe7851

What's the best way to lay out a React/webpack project with an API backend?

I'm a little late to the party, but I'm just getting started with React. I have a base project that I'm serving with webpack-dev-server, but now I need to actually get data for it.
My chosen API is Strava. I'm trying to use the recommended API wrapper for node, but I've come to a point where I don't want to expose my API keys and know that I need to create my own API endpoints. I was about to start creating an Express server to quickly create these endpoints, but I feel like there might be something that I'm missing.
Is there a better way to go about this with webpack/webpack-dev-server?
If I want this working on the internet, I know that I'll need at least one node instance running to serve my API endpoints; I just want to make sure there's not some super-simple, possibly webpack-based (to keep everything in the same family) solution that I could then, later, just deploy on a ready-made node server.
My assumption is that I'll just be better off creating two projects:
Static content (currently webpacked and served with webpack-dev-server for development)
Express server for API-wrapping.
If that's the case, is there a simple way to point hook Express up with my static project (everything webpack does is sent out to an /app/dist directory) for production deployment?

Resources