You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I downloaded some files form GitHub's master branch yesterday and modified their codes. Later, I tried to put it back to node_modules/parse-server/lib but they are incompatible. for example in Auth.js, the first 2 lines in GitHub's version are var Parse = require('parse/node').Parse; var RestQuery = require('./RestQuery');
but the first 2 lines in node_modules/parse-server/lib folder are 'use strict'; function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }. I'm using 2.3.6.
What is the preferred way to use modified parse-server source, directly modify node_modules/parse-server/lib or copy src folder to my project?
Activity
natanrolnik commentedon Feb 28, 2017
Fork parse-server, and point in your package to use your own fork.
acinader commentedon Feb 28, 2017
@jimmyzzzzzzz the parse source code is transpiled by babel.
Here's my package.json from an old branch that I needed to work on a remote machine: https://github.com/acinader/parse-server/blob/npm-git-workable/package.json
note that on line 66 I added the postinstall to build after npm has installed parse-server.....
Hopefully that helps some?
jimmyzzzzzzz commentedon Mar 1, 2017
@acinader thanks a lot for your info on babel. it helped me a lot.
I modified package.json for 2.3.6 so that it will work with npm install.
https://gist.github.com/jimmyzzzzzzz/9d259f916cbbf58f7b8f3b9a04d72975
in case anyone else needs to install the newest version from own private repo.