Repository navigation
Adding Format On Save Option (#6) - #24
Conversation
The new feature for searching for local prettier versions was merged, but readme wasn't updated
|
Sorry, I rarely use git and need to google how to squash my commits before sending a PR |
|
No comments? |
|
Hi Tom I will try to look into it tomorrow. I’m not the extension expert - so the thing about the kosher thing is properly Mads’es call - but if it looks good to me then let’s just merge it - and then maybe mads can look at it when he got the time. |
jesperbjensen
left a comment
There was a problem hiding this comment.
There is some code that looks unused.
Other than that it looks good to me - although I have no idea about the actual "Format on Save" thing.
About the squash thingy. I can squash it into a single commit - and then you will be the author. (Its part of Githubs Merge Powers)
|
|
||
| private static string _installDir = Path.Combine(Path.GetTempPath(), Vsix.Name, Packages.GetHashCode().ToString()); | ||
| private static readonly string _executable = Path.Combine(_installDir, "node_modules\\.bin\\prettier.cmd"); | ||
| private static readonly string[] _supportedExtensionRegexes = new string[] { ".jsx?", ".tsx?" }; |
There was a problem hiding this comment.
Do you use this anywhere?
There was a problem hiding this comment.
Huh.. I thought I had removed that change. That's for adding tslint support (another issue)
There was a problem hiding this comment.
Oops.. thought I had removed that. I'll update
| private static string _installDir = Path.Combine(Path.GetTempPath(), Vsix.Name, Packages.GetHashCode().ToString()); | ||
| private static readonly string _executable = Path.Combine(_installDir, "node_modules\\.bin\\prettier.cmd"); | ||
| private static readonly string[] _supportedExtensionRegexes = new string[] { ".jsx?", ".tsx?" }; | ||
| private static readonly IDictionary<string, string> _specificExtensionCommandMap = new Dictionary<string, string> // TODO: better name |
There was a problem hiding this comment.
Do you use this anywhere?
|
So, I removed that unused code, so this should be good to go unless there are other issues |
|
I’ve merged it. Good work 👍 |
This addresses #6
Not 100% sure if the implementation is Kosher or not.
NOTE: I also updated the version to 2.1 with this PR. I figured we needed to start documenting the CHANGELOG with a new version number.
Needs squashing too.