Questions tagged [loopbackjs]

LoopBack is an open source Node.js framework built on top of Express.js optimized for mobile, web, and other devices. Connect to multiple data sources, write business logic in Node.js, glue on top of your existing services and data, build REST APIs and connect using JavaScript, iOS, and Android SDKs.

The LoopBack framework is a set of Node.js modules that you can use independently or together. An application interacts with data sources through the LoopBack model API, available locally within Node.js, remotely over REST, and via native client APIs for iOS, Android, and HTML5.

Using these APIs, apps can query databases, store data, upload files, send emails, create push notifications, register users, and perform other actions provided by data sources and services. Clients can call LoopBack APIs directly using Strong Remoting, a pluggable transport layer that enables you to provide backend APIs over REST, WebSockets, and other transports.

See also

2853 questions
50
votes
25 answers

MongoError: user is not allowed to do action

I am using MongoDB Atlas as my database. I am using angular4 with loopback as api. My application connects to my database fine. However, when I try to get data, I get this error (I have replaced my dbname with dbname): MongoError: user is not…
Janpan
  • 2,164
  • 3
  • 27
  • 53
50
votes
7 answers

How to store files with meta data in LoopBack?

What I want to do: Have an html form, with a file input inside. When a file is chosen, the file input should upload the file, and get a file id, so when the form is submitted, the file id is posted with the form and written in the database. Shorter…
Mihaly KR
  • 2,363
  • 2
  • 19
  • 20
32
votes
1 answer

Destroy a model in loopback.io

How can I delete a model in strongloop's loopback.io? I have seen somewhere command called persistedModel.destroy() but when I exectute slc persistedModel.destroy() I get command not found error.
Abhishek Goel
  • 18,785
  • 11
  • 87
  • 65
31
votes
4 answers

Best practice for nodejs deployment - Directly moving node_modules to server or run npm install command

What is the best practice for deploying a nodejs application? 1) Directly moving the node_modules folders from the development server to production server, so that our same local environment can be created in the production also. Whatever changes…
Sanjay Kumar N S
  • 4,653
  • 4
  • 23
  • 38
28
votes
3 answers

Advice on loopback.js vs express js

Planning to build an enterprise level application using node js. Have already worked on express js for a few projects. When researching for other possible frameworks, came across loopback js. Loopback.js, a new framework(3-4 years) built over…
Shiva
  • 361
  • 2
  • 5
  • 13
25
votes
8 answers

How can I use body-parser with LoopBack?

I see that LoopBack has the Express 3.x middleware built-in. Indeed, body-parser is in loopback/node_modules. But I cannot figure out how to use it as middleware. I have never worked with Express 3.x, so maybe it's just that. require does not work,…
Antrikshy
  • 2,918
  • 4
  • 31
  • 65
21
votes
3 answers

Ensure unique field value in loopback model

How to ensure uniqueness of a particular field in loopback model. Like below is the model Post, I have a field genericId in it, I want it to be unique in the database, and loopback to through an error, on duplicate key insertion. { "name":…
Nishant
  • 3,614
  • 1
  • 20
  • 26
20
votes
2 answers

What is the difference between common and server models in loopback?

When I'm creating a model in strongloop with the following command: slc loopback:model loopback asks me for choose between common model or server. Common model or server only? I really don't know what criteria to take into account to choose…
Luillyfe
  • 6,183
  • 8
  • 36
  • 46
19
votes
1 answer

Add multiple dir for static files in Loopback

Loopback has two areas where paths are set for static files: server.js var path = require('path'); app.use(loopback.static(path.resolve(__dirname, '../client'))); middleware.json "files": { "loopback#static": { "params":…
Lee
  • 1,389
  • 3
  • 18
  • 28
18
votes
4 answers

How to proceed with Hybrid Mobile Application Idea?

We have monetizable Mobile Application Idea, and will be building our first mobile Hybrid application. I looked into few things and figured out that to achieve my end-to-end goal I would need: Front End UI Framework : possible options: Ionic /…
16
votes
8 answers

Auto-create mysql table with StrongLoop

I am trying to use Strongloop with MySql but cannot figure out how to migrate or automatically create tables into a MySql database. Is there at least a way to export the models into MySql schemas or do I have to manually create the tables? I've been…
glesage
  • 955
  • 2
  • 16
  • 31
15
votes
1 answer

What does "through model" mean in loopback?

When defining relation using "slc loopback:relation", it prompts about "through model" at the last line. ? Select the model to create the relationship from: CoffeeShop ? Relation type: has many ? Choose a model to create a relationship with:…
Zhou Nan
  • 151
  • 1
  • 3
15
votes
2 answers

Loopback neq: null

I'm trying a query on a postgres database through the loopback api explorer: {"where": {"archived_at":{ "neq": null }}} However, I only get results where archived_at is null?
Bunker
  • 1,040
  • 3
  • 12
  • 25
14
votes
1 answer

soap on node is parsing json to xml wrong

Using the Soap module in Nodejs (via loopback-connector-soap), I'm trying to convert json to xml for my soap request, but I have a few problems... What it is:
Geoffrey Burdett
  • 1,906
  • 1
  • 14
  • 26
14
votes
5 answers

How to Modify the StrongLoop's LoopBack Explorer CSS

We're using Strongloop's LoopBack for our REST APIs and would like to modify the CSS for the LoopBack Explorer. However, it's not clear which CSS files are being used (LoopBack vs Swagger) and where they're located. I was not able to find specific…
A2MetalCore
  • 1,621
  • 4
  • 25
  • 49
1
2 3
99 100