{ "id": "168914", "key": "AC-5077", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "8", "description": "", "name": "Needs more info" }, "resolutiondate": "2017-08-29T19:30:04.000+0000", "created": "2017-07-11T20:13:39.000+0000", "labels": [ "npm", "titanium", "web3" ], "versions": [], "issuelinks": [], "assignee": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2017-10-14T18:50:50.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "I am trying (really hard) to install a fairly important npm package.\r\n\r\nI would like to install *web3* into my mobile App project. (uses core node.js modules)\r\n\r\nHowever I am having issues with accessing it without having a bunch of red screens saying \"couldn't find module: url for architecture: x86_64\". \r\nI tried to manually update the paths etc;\r\n\r\nWhat I've done is in my App folder:\r\n{noformat}\r\nnpm install web3\r\n{noformat}\r\n\r\nThen I see the node_modules folder in my App directory... however, I am not able to require the module in my `index.js` file with a simple:\r\n\r\n{code:java}\r\nvar Web3 = require('web3'); // throws error\r\nvar web3 = new Web3();\r\n\r\nfunction doClick(e) {\r\n var version = web3.version.api;\r\n $.label.text = \"Web3 version: \" + version;\r\n}\r\n\r\n$.index.open();\r\n{code}\r\n\r\nNow I've pasted the folder from the `node_modules` into a `lib` I created under App folder, and tried to access the `dist` within that to access `web3.min`, then tried a whole lot of other things, with no luck... has anybody else had such issue or have a solution?\r\n\r\nAdam Paxtom has mentioned that: \"The Node.js support, at least currently, appears to be best suited for standalone js libraries.\" \r\n\r\nI hope there isn't much need for convincing this issue aught to be a high priority.", "attachment": [], "flagged": false, "summary": "Ti 6.x cannot install full nodejs module", "creator": { "name": "underlabs", "key": "underlabs", "displayName": "Joseph Sachs", "active": true, "timeZone": "America/Montreal" }, "subtasks": [], "reporter": { "name": "underlabs", "key": "underlabs", "displayName": "Joseph Sachs", "active": true, "timeZone": "America/Montreal" }, "environment": null, "comment": { "comments": [ { "id": "424984", "author": { "name": "underlabs", "key": "underlabs", "displayName": "Joseph Sachs", "active": true, "timeZone": "America/Montreal" }, "body": "Hi Guys, Any update on this issue?\r\n\r\nAt the very least is there a way to +npm install web3.js *in the mean time*+ *if *the ability to install full npm modules *will take time* to be part of Titanium?", "updateAuthor": { "name": "underlabs", "key": "underlabs", "displayName": "Joseph Sachs", "active": true, "timeZone": "America/Montreal" }, "created": "2017-07-27T19:16:31.000+0000", "updated": "2017-07-27T19:18:09.000+0000" }, { "id": "425115", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2017-07-31T19:24:10.000+0000", "updated": "2017-07-31T19:24:10.000+0000" }, { "id": "427051", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "Let us know if you still facing the issue.", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2017-08-22T19:54:56.000+0000", "updated": "2017-08-22T19:54:56.000+0000" }, { "id": "429100", "author": { "name": "jfalcone", "key": "jfalcone", "displayName": "Joe Falcone", "active": true, "timeZone": "America/Los_Angeles" }, "body": "We've just started trying to use Node modules with SDK 6 and we are also running into similar problems. The only examples I can find out there are people who have given up trying to using the Node modules and just included the .js files from the modules and their dependencies into Resources which defeats the purpose of using Node modules in the first place. Several people have asked where exactly to install the Node modules in the source hierarchy (with and without Alloy) and I've seen no answers other than read the documentation which is obtuse to say the least. I would suggest that Titanium provide a genuine example using a real Node module from NPM which would provide a clear answer to all of us. ", "updateAuthor": { "name": "jfalcone", "key": "jfalcone", "displayName": "Joe Falcone", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2017-10-14T18:50:50.000+0000", "updated": "2017-10-14T18:50:50.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }