We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
import
I just run ImportJS on a huge codebase and the results are mostly good, but this one seemed peculiar enough for me to report it:
I'm not too familiar with the lib, but in this case it broke the code by sorting two variable assignments in false order.
Used ImportJS 3.2.0 on Mac OS, via CLI:
find ./client -name "**.js*" -exec importjs fix --overwrite {} \;
//.importjs.js module.exports = { declarationKeyword: 'import', environments: ['meteor', 'node'], excludes: ['.meteor/local/**', '.vscode/**'], mergableOptions: { globals: false, }, useRelativePaths: true }
The text was updated successfully, but these errors were encountered:
What I see after hitting ctrl + shift + i
ctrl + shift + i
Once I click through all the options all import statements disappear. But I can ctrl + z to go back to the block pictured above.
ctrl + z
Sorry, something went wrong.
I couldn't reproduce this behavior. Probably it has been fixed since this issue was created (we're on v5.2 now, this issue is for 3.2).
I'll close this, but please reopen if anyone can reproduce. Thanks.
Apologies, my test had a typo. I can now reproduce some of it.
On current master, empty project with no dependencies:
import Quill from "quill"; const Parchment = Quill.import("parchment"); const Block = Parchment.query("block"); const a = "some code after";
becomes
import Quill from "quill" const Parchment = Quill.import("parchment") const a = "some code after";
While it didn't move the line for me, it still deleted it. I'm guessing ImportJS somehow misinterprets the Quill.import method to be a dynamic import.
Quill.import
This is the smallest reproducible I could achieve:
let l = a.import("")
These conditions need to be present for this bug:
const
var
let
foo.import
let l = import("")
No branches or pull requests
I just run ImportJS on a huge codebase and the results are mostly good, but this one seemed peculiar enough for me to report it:
I'm not too familiar with the lib, but in this case it broke the code by sorting two variable assignments in false order.
Used ImportJS 3.2.0 on Mac OS, via CLI:
The text was updated successfully, but these errors were encountered: