Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

include javascript modules? #14

Closed
bradparks opened this issue May 27, 2015 · 2 comments
Closed

include javascript modules? #14

bradparks opened this issue May 27, 2015 · 2 comments

Comments

@bradparks
Copy link

Is there anyway to use javascript libraries in the included js file? something like require but for nodejs ?

@bang590
Copy link
Owner

bang590 commented May 28, 2015

Nope, if you want to exec multiple js files, you can do it in OC:

[JPEngine startEngine];
for (NSString *jsFilePath in jsFilePaths) {
    NSString *script = [NSString stringWithContentsOfFile:jsFilePath encoding:NSUTF8StringEncoding error:nil];
    [JPEngine evaluateScript:script];
}

@bradparks
Copy link
Author

cool.. thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants