Closed kanlukasz closed 5 months ago
Hi @kanlukasz,
Thank you for creating the issue. Can you give me the following information:
{% extends 'front/layout.html.twig' %}
{% set title = ( 'Home'|trans) ~ ' — Apollon' %}
{% block body %}
{% set params = {
'defaultPost': {
'users': [
{
'name': 'Ama',
'image': asset('front/images/feed-default-ama.png'),
'image_retina': asset('front/images/feed-default-ama@2x.png')
},
{
'name': 'Hermann',
'image': asset('front/images/feed-default-hermann.png'),
'image_retina': asset('front/images/feed-default-hermann@2x.png')
}
],
'title': "Welcome Apollonians!"|trans,
'subtitle': "Founder of Apollon"|trans,
'date': "October 31, 2020 at 12h"|trans,
'content': "Find here the people and stories that inspires you"|trans,
'action': "Discover"|trans
}
} %}
<feed-component :params="{{ params|json_encode }}" />
{% endblock %}
"[twig]": {
"editor.defaultFormatter": "artagnon.vstwig"
},
Thanks and warm regards.
Hi @artagnon, Thank you for your response. Below, I describe all the necessary details. ​​​​
- Does formatting work on any other twig document, or does VSTwig not work in general for you?
The VSTwig formatter generally doesn't work on file that i tested yesterday. I'll check your sample file in a moment ​​​​
- Can you try VSTwig with the following document?
Something happened (as you can see in the gif example), but now it's the wrong formatting ​​​​
- Can you paste me the document that fails?
The file I tested that doesn't work is the original twig file from the Symfony Demo Blog from Github. It is here ---> https://github.com/symfony/demo/blob/main/templates/base.html.twig ​​​​
- Can you try adding the following to your settings.json, after making sure to remove any conflicting settings?
I added this. Anyway conflict is impossible as I test your addon on a new and fresh install on VSCode without any addons or custom settings
Hello @kanlukasz. Sorry for the delay, but I finally got around to looking at the issue this morning. It seems that the issue is Windows-specific, and has to do with hard-coding "\n" in several places. I've attempted to fix the issue now, although I don't have a Windows machine to test. Could you kindly report how vstwig 0.0.7 performs?
Warm regards.
Hello
Unfortunately, it still doesn't work properly. Examples below
CRLF
and LF
):Hi @kanlukasz. Sorry for the long delay: I don't actually use Twig anymore, but found some time to fix the bugs nevertheless, as vstwig is a popular extension. Could you kindly verify that the issues are all fixed with 0.0.10?
Closing due to lack of response. Please re-open if issue persists.
It seems that formatting does not work
Example below (GIF Video):
Tested on:
Additional info:
After re-loading the VSCode, Dev Tools Console returns the following warning:
Let me know if you need more information or more tests