-
Notifications
You must be signed in to change notification settings - Fork 1
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
Added code highlight for ftd
in ide
#113
base: main
Are you sure you want to change the base?
Conversation
@@ -17,6 +17,7 @@ import { | |||
} from "./panels/package/package-content"; | |||
import {indentationMarkers} from '@replit/codemirror-indentation-markers'; | |||
import {CommandEditor} from "./command-k/command-editor"; | |||
import {ftd} from "./ftd/language"; |
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.
Let's call it ./fastn/language
etc. FTD is no longer the name, we want to use fastn language terminology everywhere.
components/editor/ftd/ftd.grammar
Outdated
@@ -0,0 +1,12 @@ | |||
@top ImportCommand { "--" "import" ":" Name } |
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.
You can create p1 level grammar only, try to port our old grammar, instead of creating full parser.
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 would love full parser, but it would be more work. Also the language support for fastn should be in fastn-stack org, so others can also use it.
@@ -0,0 +1,42 @@ | |||
|
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.
This should be ideally a standalone npm package.
@@ -1,6 +1,7 @@ | |||
{ | |||
"scripts": { | |||
"prepare": "lezer-generator command-k/command.grammar -o command-k/parser.js" | |||
"prepare": "lezer-generator command-k/command.grammar -o command-k/parser.js", |
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.
Dont' add a new command, make it part of prepare, use && to separate both commands.
@@ -204,7 +204,7 @@ ide_dispatch_event(name, data) | |||
|
|||
|
|||
;; full-name of current file | |||
-- optional string $current-file: | |||
-- optional string $current-file: sfd |
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 this is intentional, explain in a comment why sfd or why it can't be left null.
No description provided.