Questions tagged [adonis.js]

Adonis is a full stack, open source MVC framework for Node.js. The framework is inspired by the PHP framework Laravel.

AdonisJs is an MVC Framework for Node.js.

It includes:

  • Lucid ORM
  • Database Migrations
  • Authentication System
  • OAuth
  • Mailing System
  • Data Validator
  • Testing

Learn more on the website and check out the organization on Github.

572 questions
49
votes
6 answers

How can I solve error gypgyp ERR!ERR! find VSfind VS msvs_version not set from command line or npm config?

I want to run this project : https://github.com/adonis-china/adonis-adminify When I run npm install, there exist error : > sqlite3@3.1.13 install C:\laragon\www\adonis-admin\node_modules\sqlite3 > node-pre-gyp install…
Success Man
  • 5,513
  • 23
  • 109
  • 205
8
votes
1 answer

AdonisJS - How to return validation messages according to the locale of Antl Provider

I'm applying internationalization to my API and I'm having some issues related to Antl and validation messages. With standard response messages, I'm returning according to the locale set by the user. I created a route to switch locales and set to a…
Laura Beatris
  • 862
  • 3
  • 10
  • 32
8
votes
1 answer

React with Adonis

I am trying to integrate React with Adonis Js to build an SPA. Adonis handles routing to an SPA by Route.any('*', function * (request, response) { yield response.sendView('home') }) I have done exactly that in app > Http > routes.js Then I created…
Roy
  • 319
  • 1
  • 3
  • 11
6
votes
0 answers

Jest integration with Adonis V5

I'm developing an application with Adonis v5 but its test runner isn't finished. So, my workaround is to apply Jest in its place. I got this working but I'm having trouble importing types from Adonis. In any model, I have the following…
leandroungari
  • 131
  • 1
  • 7
5
votes
1 answer

Error in G * t(hat) : non-conformable arrays

Trying to carry out a PERMANOVA using adonis in R. Added in my data table and factors, however, I keep getting the sample error - Error in G * t(hat) : non-conformable arrays There is no N/A data, and it works with a ready made matrix of data and a…
Bex
  • 51
  • 1
  • 2
5
votes
2 answers

what is the 'use' keyword in javascript?

I am looking at this specific line of code to understand what it is or to find some documentation about it. https://github.com/adonisjs/adonis-rally/blob/c7378d2c3984bffba1049f50e771318ea447107c/app/Model/Channel.js const Lucid = use('Lucid') I am…
shed_fortest
  • 61
  • 1
  • 3
5
votes
2 answers

Adonis JS - Hashing Password

I have gone…
Roy
  • 319
  • 1
  • 3
  • 11
4
votes
1 answer

Maximum call stack size exceeded error while using .save() function in AdonisJS

I am trying to create a seeder file in AdonisJS. I have a simple seeder file which adds 2 users in the database. UserSeeder.js 'use strict' /* |-------------------------------------------------------------------------- |…
4
votes
1 answer

How can I use nginx with adonis?

I'm try to make a deploy of one api adonis and I'm trying to use nginx to enable external access to my http requests. I install nginx and go in ssh I go to: cd /etc/nginx vi nginx.conf So, I put this code: #user nobody; worker_processes …
bla
  • 667
  • 4
  • 19
4
votes
1 answer

How i can alter a column type without lose the database data in migration using adonis?

I have this class: class BookUnitQuestionSchema extends Schema { up () { this.create('book_unit_question', (table) => { table.increments() table.integer('book_unit_id').references('id').inTable('book_unit') …
bla
  • 667
  • 4
  • 19
4
votes
1 answer

fetch query returning empty array when using params

I'm trying to fetch some values from a mongodb collection using lucid-mongo, and it's returning me an empty array. The functions are essentially copied from others I have somewhere else in my code, just changing where some values are. The params.id…
Filipe
  • 43
  • 4
4
votes
1 answer

How to share code between controllers in adonis js

can anyone suggest me how can I use a custom class for writing all helper methods so that the app doesn't repeat same code again and again in different controllers? How can I share codes between controllers? Thank you
Hkm Sadek
  • 2,348
  • 5
  • 26
  • 62
4
votes
2 answers

Persisted state from VueX and NuxtJS

I use vuex-persistedstate package (https://github.com/robinvdvleuten/vuex-persistedstate) to persist data state on browser. I use Adonuxt (a mix between NuxtJS and AdonisJS). In VueX actions, I have this action: nuxtClientInit ({commit}) { //…
pirmax
  • 1,508
  • 5
  • 21
  • 53
4
votes
3 answers

Socket.io with Adonis.js

I am using Adonis 4.1.0 and Adonis-websocket is only been available for v3. Can anyone tell me workaround for using socket.io with Adonis 4.1.0?
Tijan Manandhar
  • 182
  • 2
  • 17
4
votes
2 answers

Ignore specific error for eslint in the whole project

I'm using AdonisJs (NodeJS framework) and they created a function called use to import file like they'd be namespaces, for example use('App/Services/User') instead of require('../app/Services/User'). The problem is that eslint will throw the error…
Theraloss
  • 660
  • 2
  • 8
  • 26
1
2 3
38 39