-
Notifications
You must be signed in to change notification settings - Fork 42
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
fix: declared types in models repository - I153 #173
fix: declared types in models repository - I153 #173
Conversation
Signed-off-by: Apoorv Saxena <[email protected]>
build.js
Outdated
@@ -14,6 +14,7 @@ | |||
|
|||
'use strict'; | |||
|
|||
process.env.SERVER_ROOT = "https://models.accordproject.org"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of hardcoding this in build.js can you please set it in package.json where the script is called?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made some changes. SERVER_ROOT
is now declared as an environment variable at the time of execution.
@@ -38,7 +38,7 @@ | |||
<div class="content box"> | |||
<pre style="border: 0; background-color: transparent;"> | |||
<code class="js"> | |||
{% for decl in modelFile.getAllDeclarations() %}import {{decl.getFullyQualifiedName()}} from {{serverRoot}}{{filePath}}.cto |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think the import should be quoted in CTO syntax.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If quotes are removed, the part of the statement after "https:" is displayed as a comment, due to syntax highlighting (using highlight.js). It probably detects the code as javascript
As a workaround, I ended up skipping syntax-highlighting for this code block altogether. So this is how it looks now-
Signed-off-by: Apoorv Saxena <[email protected]>
Signed-off-by: Apoorv Saxena <[email protected]>
@dselman. Could you please see if any changes are required? |
Closes #153
Fixed incorrectly generated import prefix on the models website.
Changes
SERVER_ROOT
environment variable.Screenshots or Video
Author Checklist
--signoff
option of git commit.main
fromfork:branchname