attilabuti / vscode-mjml

This repo is archived. MJML preview, lint, compile for Visual Studio Code.
https://marketplace.visualstudio.com/items?itemName=attilabuti.vscode-mjml
MIT License
144 stars 59 forks source link

Update Preview with current active document? #25

Closed michaelroper closed 6 years ago

michaelroper commented 6 years ago

Hi Attila!

If I have multiple MJML files in my VS Code project, and I switch between them, the preview window will only show the preview for the first document it was opened for. It also won't update to show the preview for subsequent documents, even if I re-run the "Preview to Side" command. The only workaround seems to be closing the preview window, and running the preview command again on the other document.

Is it possible to update the preview window after switching documents to show the current active document, similar to the way the MJML desktop app functions?

Thanks!

attilabuti commented 6 years ago

This will be implemented in the next version.

michaelroper commented 6 years ago

Awesome, thanks Attila!

attilabuti commented 6 years ago

Released in v1.3.0

deviant32 commented 6 years ago

Doesn't seem to work for me, every time i open a new email it opens over the preview panel. I added "mjml.autoPreview": true to the user config and restarted.

attilabuti commented 6 years ago

Hello @deviant32

First of, what is your operating system and its version? Which version of VSCode you are using? Also which version of the extension are you running?

I have tested this on Windows and Ubuntu, and it worked well.

deviant32 commented 6 years ago

VS Code: Version 1.23.1 (1.23.1) Mac OSX 10.13.4 MJML extension 1.3.0 MJML 4.0.5