Titanium Module (Android) - "Requested module not found" - javascript

I'm creating a module and adding it to an application
application structure:
module structure:
access code module:
var module = require('ar.com.module');
$.label.text = module.example();
error:
steps to run application:
include module in app
clean and build app
run to device
Titanium SDK version: 3.2.0.GA
NDK Android: r8
Android plataform (module): android-10
solution to this problem?

Solution:
to run the module in a device must be configured deploy-type = "test" in tiapp.xml and install gperf add to Path.

Related

Ionic and ssh2: Error: process.binding not supported

I am trying to learn Ionic and I am attempting to create a simple application that uses SSH2 to establish an ssh connection between application and server. The following are the steps that I did in order to get the problem:
Steps to reproduce:
Create application: ionic start app_name tabs
cd to app_name directory
npm install --save ssh2
open project, go to any page (e.g. home.ts) and import ssh2 from 'ssh2';
Inside constructor type: console.dir(ssh2); Run ionic serve
Get Error: Cannot find module: dns and solved by adding dns: 'empty' to /config/webpack.config.js
Run application again and get Error: process.binding is not supported
I am using the following:
Ionic Framework: 3.9.2
Ionic App Scripts: 3.1.10
Angular Core: 5.2.11
Angular Compiler CLI: 5.2.11
Node: 8.11.2
OS Platform: Windows 10
Thank you Suraj! It seems like ssh2 is written only for node.js
Can you use the node package ssh2 in a browser?

JS server already running react native app

I'm following the Getting Started tutorial from here: https://facebook.github.io/react-native/docs/getting-started.html. I'm able to boot up my package manager with react-native start. But running the application itself always results in a crash.
$ react-native run-android
JS server already running.
Building and installing the app on the device (cd android && gradlew.bat installDebug...
Error occurred during initialization of VM
Unable to use shared archive.
An error has occurred while processing the shared archive file.
Unable to unmap shared space.
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/android-setup.html
What is the problem?
You already have a react native process running in the background on the same port.
Use ps -ef | grep react
and then kill the process using the process id
kill -9 pid
and then re execute the command:
react-native run-android
First of all give proper permission to your gradlew, in your root directory run following command
chmod 755 android/gradlew
After this make sure you have local.properties file in your android folder with sdk file path like
sdk.dir = /home/username/Android/Sdk/

Building Meteor app returns Error: EPERM, symlink

I'm attempting to build a Meteor application in an offline environment, with local web servers but no access to the outside Internet.
On running meteor build ./output I get the following:
...AppData\Local\.meteor\packages\templating\1.1.9\plugin.compileTemplatesBatch.os\npm\node_modules\meteor\promise\node_modules\meteor-promise\promise_server.js:116
throw error;
Error: EPERM, symlink '..\babylon\bin\babylon.js'
This application runs fine in localhost, doesn't seem to have any issues, but on attempting to build or bundle the app I run into these issues.
Additional (perhaps useful) info:
meteor build ./output --verbose returns the following (unnecessary packages omitted)
Local package version is up-to-date: templating#1.1.9
Local package version is up-to-date: templating-tools#1.0.4
Thanks
You need to run meteor as an administrator, then it can create the symlinks.

I get a "Failed to load resource" for Cordova error when trying to run the blank ionic starter app

I'm trying to get the blank Ionic starter app running (1.2.4); and I get this error after installing Ionic and trying to run their demo app:
Console:
[Error] Failed to load resource: The requested URL was not found on
this server. (cordova.js, line 0)
How do I resolve the 'failed to load resource' error for cordova?
According to the Ionic Framework Website, you need to do the following steps:
Install Node.js 4 (Not Node 5):
Using Homebrew:
brew tap homebrew/versions
brew install node4-lts
when NPM is installed, run this:
npm install -g cordova ionic
That installs cordova and Ionic globally.
Once you do that, your ionic start myApp starter should build and install the necessary items to have a blank Ionic app.
I can't give you instructions on how to install it other ways (there are so many ways to install it depending on your OS.

Installing node.js for angular - connect.static and karma

I'm trying to install a simple node webserver following the example in Pro AngularJS from apress.
I've installed node.js and the connect and karma modules.
I do get a warning when I installed karma via: "npm install -g karma" that says "optional dep failed, continuing" but then seems to install correctly.
I created a server.js based on the example:
var connect = require('connect');
connect.createServer(
connect.static("../angularjs")
).listen(5000);
when I run it I get TypeError:Undefined is not a function pointing to connect.static.
Apparently in the latest build of connect the static middleware has been moved to it's own package.
nodejs connect cannot find static

Categories