-
Notifications
You must be signed in to change notification settings - Fork 14
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
[0.9.0] linthtml()
function doesn't default export
#471
Comments
@regseb Thanks for reporting, I'll look into it. |
Seems like this breaks the LintHTML VSC extension. Celan install of both resluts in the error message "linthtml: lintHTML is not a function. Check your config file" when I open a html file in VSC. |
I've started invetigating the problem. |
I am developing a project that aggregates several linters (using at API) : Metalint. I integrate LintHTML and I found this difference by upgrading to version 0.9.0. I can work around it, but I reported this problem because I don't think this change is voluntary. |
I'm happy to hear of people using LintHTML to build other things. |
@regseb So, I had a look, and because the codebase is now written in Typescript, it's not possible to bring back the previous export. |
@HOKComics The latest version has a fix for the vscode extension |
If the default export isn't possible, the
|
@regseb I need to think about it. Changing the export once again has many impacts, I'll need to update the vscode extension once again to support 3 different kind of export 😓 . I'm not sure it's good idea |
You can keep the default export to not break the API. And add the normal export of the
linthtml/packages/linthtml/lib/index.ts Line 151 in f75f84a
- export { config_from_path, find_local_config, LegacyLinterConfig, LinterConfig };
+ export { linthtml, config_from_path, find_local_config, LegacyLinterConfig, LinterConfig }; |
htmllint()
function doesn't default exportlinthtml()
function doesn't default export
Version 0.9.0 no longer exports the
linthtml()
function by default. I think the problem is with the TypeScript transpiler or the module bundler, because index.ts exports function by default.With 0.9.0:
With 0.8.6:
The text was updated successfully, but these errors were encountered: