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

Macro syntax in template path for accessing built-in templates #48

Closed
NQNStudios opened this issue Dec 20, 2017 · 2 comments
Closed

Macro syntax in template path for accessing built-in templates #48

NQNStudios opened this issue Dec 20, 2017 · 2 comments

Comments

@NQNStudios
Copy link
Collaborator

When running fractive from the command line via a global npm installation, it becomes very difficult to reference one of the example templates in an original story without copying the file to a new location relative to the story, not the fractive installation.

I'm thinking we could implement a hackish macro for that like letting the user write the path $(builtin)/basic.html in fractive.json and Compiler.ts would interpret that into the path of the fractive installation.

@NQNStudios
Copy link
Collaborator Author

Note: at compile time, the global __dirname variable contains the path of the current source file (i.e. fractive/lib. We can use this to access the location of the fractive installation.

@NQNStudios
Copy link
Collaborator Author

Closed by #49.

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