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

LSP Server Support #58

Open
wants to merge 50 commits into
base: mathpoly
Choose a base branch
from
Open

LSP Server Support #58

wants to merge 50 commits into from

Conversation

b-studios
Copy link
Member

This PR is only for discussion and should (not yet) be merged

To implement an LSP Server for madoko, we need to extract some information about the document. This branch tries to simplify this process.

package.json Outdated
],
"preferGlobal": true,
"main": "./lib/madoko.js",
"main": "./lib/api.js",
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here I changed the main file to access analyze instead of madoko. We need to change this to allow both.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I merged the two interfaces and changed it back, so it should be mostly backwards compatible , modulo the change of the return type of markdown:

- (string,options)
+ (string,options,list<block>,formatContext)

@@ -138,7 +138,7 @@ function parseDefinitionsFull(
// set label
if (attrsx.name != "") then {
val labelCaption = attrsx.hasKey("caption").maybe("",id)
labels[attrsx.name] := Label(bname,attrsx.label,labelCaption)
labels[attrsx.name] := Label(bname,attrsx.label,labelCaption,attrsx)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was important to get the position information on the label

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

Successfully merging this pull request may close these issues.

2 participants