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

Infinite Loop when trying to delegate the request. #55222

Closed
jens1o opened this issue Jul 27, 2018 · 3 comments
Closed

Infinite Loop when trying to delegate the request. #55222

jens1o opened this issue Jul 27, 2018 · 3 comments
Assignees

Comments

@jens1o
Copy link
Contributor

jens1o commented Jul 27, 2018

Okay, I'm working on implementing this. I've got one problem though. When I pass vscode the request, it apparently passes it back to me, then I pass it to vscode... Infinite Loop. How can I get around this and declare the specific code-part as another language, so (in my example) the Emmet provider rules it all?

That's the code currently: https://github.com/jens1o/vscode-smarty/blob/a558eb202f91c7657904e4c39a2844529e06fb39/src/completionProvider.ts#L28-L41

#47288

@aeschli
Copy link
Contributor

aeschli commented Jul 30, 2018

You need to create a new text document with languageId: html. The content also has to be HTML. In that document, you have to clean out all smarty templating syntax that can interfere with the html syntax.
When doing that, the best is to just put whitespaces at the places where the smarty syntax is, so that positions for the code assist (and the result) stay the same.

@jens1o
Copy link
Contributor Author

jens1o commented Jul 30, 2018

Alright, thank you. I'll try it.

@aeschli
Copy link
Contributor

aeschli commented Jul 30, 2018

Marking as closed

@aeschli aeschli closed this as completed Jul 30, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Sep 13, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants