Skip to content
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

[script-compiler] Can morpheme-match dictionaries be bundled with worker? #60

Open
doujinreviewers opened this issue Jan 1, 2022 · 1 comment

Comments

@doujinreviewers
Copy link

If .textlintrc has a morpheme-match "dictionaryPathList" set, it will continue to show relative paths even when built with script-compiler.

{
  "rules": {
    "@textlint-ja/morpheme-match": {
      "dictionaryPathList": ["./dictionary.js"] 
    }
  }
}

This means that need to have an external dictionary file even after compiling textlint as a worker.
Can dictionary files also be bundled within the worker?

@azu
Copy link
Member

azu commented Jan 1, 2022

No, not at the moment.
because, fs module is not work in browser.

As related, textlint-rule-prh is supported.
@textlint/config-inliner inline dictionary file to textlint worker script.
We need to add handling to @textlint/config-inliner for supporing @textlint-ja/morpheme-match.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants