node.js web service for mobile apps [closed] - javascript

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I would like to create a web service for a mobile app chained to a mongodb where I would store some user specific data. Since I'm new to node and I just finished reading the Node.js in Action book by Mike Cantelon & Tj Holowaychuk I am now trying to think which framework should I use in order to create the server. I think it would be either connect or express but I am not sure. I saw that express is used mostly for creating web apps rather than web servers. What do you guys recommend me? In addition some tutorials to get me started in this direction would be most welcome. Thanks.

I prefer to use express, It is common in developping node.js application and you will find a lot of tutorials that will help you. Also express provide you with RESTful API which will help you a lot to access your data from mobile
and these are some links to help you to start with express
http://net.tutsplus.com/tutorials/javascript-ajax/introduction-to-express/
http://blog.ijasoneverett.com/2013/03/a-sample-app-with-node-js-express-and-mongodb-part-1/
http://blog.modulus.io/nodejs-and-express-create-rest-api

Express uses Connect, and is fine for most applications. It will certainly be fine for, "a web service for a mobile app chained to a mongodb where I would store some user specific data."
It isn't possible to give a more specific recommendation, as you provided no specific details in your question.
I saw that express is used mostly for creating web apps rather than web servers.
This doesn't make much sense really. Node.js provides the server http.Server and you create the application layer behind it. Express is often used to provide common functionality such as routing and a Connect stack of modules for handling requests.

Related

Can we use python with react? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
The community reviewed whether to reopen this question 1 year ago and left it closed:
Original close reason(s) were not resolved
Improve this question
I have seen many people are using Nodejs with reactjs but I liked python and react so much that I wanted to know if I could python with react. If so could you please give me some links for learning that please
I have experience building web applications using React and Python Flask together, so perhaps I can help.
I do not know of a way to directly use Python on client-side web applications, but there are certainly plenty of ways to use Python on the backend. The most popular Python web frameworks are Flask and Django.
If so could you please give me some links for learning that please
YouTuber Corey Schafer has a great YouTube tutorial series on Flask, which I would wholeheartedly recommend.
Once you get more comfortable with web development in Python, I think the website https://realpython.com/ has great tutorials for both specific questions (e.g. Token-Based Authentication in Flask) and more general tutorials.
If you go with Django, it has a great ORM built in for working with databases.
If you go with Flask, which is definitely more beginner friendly IMO, I would recommend Peewee ORM for working with relational databases unless you have more complicated use-cases, in which case SQLAlchemy is the de-facto standard.
Good luck learning!
Update
I just came across this cool Python library called Transcrypt that transpiles Python code into JavaScript, so it turns out you can write client-side code for the web in Python. Their website has some cool tutorials.
Yes. React is mostly agnostic of what's going on at the server-level.
ie it does not care what backend you use.
Check this example : https://realpython.com/the-ultimate-flask-front-end/
https://plotly.com/dash
I have been using this to build up react app with python.
They have new libs 'dash' and dash component whose underlying is react.js.
React is backend-agnostic.
React manages the UI, which possibly interacts with some HTTP APIs regardless in what language they're made of.
What's important is that your API use some standard like REST, jsonapi or GraphQL so you can benefit a wide range of tools (documentation, tests...)
That said, if you want to make "server-side-rendered" react web apps, like Next.js does, or if you need WebSockets, you'll need NodeJS on the server-side too. Also, the ability to use the same code, tooling and ecosystem on the client and the server is useful for a developer.

Do I need to use Express or other library to make a server that only return JSONs using node? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
I'm testing node js and so much questions are coming to my head. I want to make a server to a mobile app that just response data I need from a database. That is not so complicated but all people I see use Express with node but when I take a look to Express seems that is like it only give you help if your target is a web app (probably I'm wrong). I've reached get a data from my mongodb database calling my node server but all in node js raw code. I want to know if exists other library for API REST use that could help in a mobile develop or in fact, if I will have to still working in raw node (that is not a really problem). I'm new in node so probably I'm leaving some concepts. To make this the app I'm using React-Native. It could be important to know.
Express is a framework that will simplify development alot. You are not forced to use it, just keep in mind that without it, you will have no router, no middlewares, and no anything coming with Express.
You can, but it will be harder if your app becomes big.
Hope it helps.
You can use express to do the same. Or you an use any other framework like sails,koa. But most of the frameworks are based on express and from my experience express is the best to do this. I have been running express with similar purpose for the past 3 years.
Express provides basic features like routing, creating server, error handling.You can plug whatever libraries to express to do better.

how to create a website / webpage that performs backend server activities [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
First up, I am not very sure If I am posting in the right stackexchange site. Apologize if I am posting in wrong site. Please correct me If I am wrong.
I am new to web development, Perhaps I am trying to build my first ever site for my client. We already have a old site/page which I wanna rewrite with better UI & UX.
I am trying to understand what are the technologies I need to know to build this site. The basic functionality I am looking at are
help user to rename, move or copy files on the server where they
don't have access to modify files directly.
Interact with Database and pull some information
Reset password from logon page
Building queries for users
Kick off jobs
I believe HTML & CSS would be a need for the design part but I want to know which technology will help me complete the background tasks... Is it Javascript or PHP etc.. Server that I need to be running like Apache Tomcat etc
Finally If you know of a good book which could help me traverse, Please share.
Thanks a lot in advance.
It sounds like you're on the right track. If you're planning on recreating a web application, I would check out the "LAMP" stack, which covers most of the technologies needed in putting this together. I can't recommend a book, but there are tons of resources online that can get you started.

Is there any similar boilerplate like MEAN stack for SailsJS? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I have to develop a new blog for myself. I have recently got acquainted with AngularJS, mongoDB, node, sails, etc. I have got some primitive knowledge about all these to start the development.
So, I was looking for something similar to http://mean.io/, MEAN stack. But instead of using ExpressJS, I am gonna use SailsJS. Is there anything similar to MEAN but works with SailsJS as well? Or is there any other approach to the same, considering I am also gonna use AnuglarJS for front-end and mongoDB for my database?
AFAIK, there's no branded Sails-based alternative to http://mean.io/ yet, though some people were talking about MEANS stack already.
That being said, you have several choices for creating an Angular+Sails app. One of them is using Yeoman generator, like this one.
Another way could be this boilerplate which is somewhat official, as it's published by Balderdash, the company behind Sails. Though when I tried to test it, dependency installation was failing, so I fixed it on this fork. This boilerplate is based on the brand new Sails v0.10. Also, you are going to have to do is to connect it to your MongoDB (the default is sails-disk), see here for how-to.

Good server-javascript host/framework? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I'm trying to find a good javascript based web host, as well as a good server-side javascript implementation. I have played some with NodeJS, and it seems very good, but I really don't want to have to write the entire server from scratch. I need a host/framework with the following features (or at least most of them):
1: The ability to run a script continuously on the server while maintaining a continuous dialog with other scripts as well as client pages (through xmlhttprequest).
2: PHP/ASP like functionality.
3: I don't want to have to write an entire server from scratch. I just want to worry about writing my application.
Also, I have recently been looking into Aptana's Jaxer, which seems to be the holy grail from my perspective, but when I go to the web site "www.jaxer.org", it returns a completely irrelevant page. Could somebody please explain this to me?
Thanks,
Chris
I've used https://no.de/ from joyent to host my node.js applications.
For communicating between the client and the server I'd use http://socket.io/ . It's a communication framework that will choose the most appropriate communication method to maintain a connection (continuous dialog) with the client.
For serving static content see this answer for a link to a great article on a simple web server.
Using node.js as a simple web server
Or see this answer that discusses various web application frameworks.
https://stackoverflow.com/questions/3809539/choosing-a-web-application-framework-using-node-js
Hope this helps, & Good luck on your project!
You could have a look at Wakanda
It provides a full stack including, the server, the studio, and the client framework, all in a very consistent way.
There is a related question I answered on stackoverflow about where to host Wakanda applications, and another one comparing different existing server-side JavaScript solutions

Categories

Resources