Skip to content

jsCodeLocation choice #821

Closed
Closed
@nkt

Description

@nkt

Why jsCodeLocation couldn't be defined by compiler, instead of programmer?
I've googled, XCode provide DEBUG macro, so we could do something like this:

#if DEBUG
  jsCodeLocation = [NSURL URLWithString:@"http://localhost:8081/index.ios.bundle"];
#else
  jsCodeLocation = [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
#endif

And also add compilation callback that would be update main.jsbundle.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions