@astrojs/check 0.6.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +38 -0
- package/dist/index.js +1 -3
- package/package.json +4 -2
package/README.md
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# @astrojs/check ✅
|
|
2
|
+
|
|
3
|
+
This package powers the `astro check` CLI command for running type checking and diagnostics in Astro projects.
|
|
4
|
+
|
|
5
|
+
This package's internal logic is powered by [the Astro language server](https://github.com/withastro/language-tools/blob/main/packages/language-server/src/check.ts).
|
|
6
|
+
|
|
7
|
+
## Documentation
|
|
8
|
+
|
|
9
|
+
Read [the Astro type checking docs][docs].
|
|
10
|
+
|
|
11
|
+
## Support
|
|
12
|
+
|
|
13
|
+
- Get help in the [Astro Discord][discord]. Post questions in our `#support` forum, or visit our dedicated `#editors` channel to discuss current development and more!
|
|
14
|
+
|
|
15
|
+
- Submit bug reports and feature requests as [GitHub issues][issues].
|
|
16
|
+
|
|
17
|
+
## Contributing
|
|
18
|
+
|
|
19
|
+
This package is maintained by Astro's Core team. You're welcome to submit an issue or PR! These links will help you get started:
|
|
20
|
+
|
|
21
|
+
- [Contributor Manual][contributing]
|
|
22
|
+
- [Code of Conduct][coc]
|
|
23
|
+
- [Community Guide][community]
|
|
24
|
+
|
|
25
|
+
## License
|
|
26
|
+
|
|
27
|
+
MIT
|
|
28
|
+
|
|
29
|
+
Copyright (c) 2022–present [Astro][astro]
|
|
30
|
+
|
|
31
|
+
[astro]: https://astro.build/
|
|
32
|
+
[docs]: https://docs.astro.build/en/guides/typescript/#type-checking
|
|
33
|
+
[contributing]: https://github.com/withastro/language-tools/blob/main/CONTRIBUTING.md
|
|
34
|
+
[coc]: https://github.com/withastro/.github/blob/main/CODE_OF_CONDUCT.md
|
|
35
|
+
[community]: https://github.com/withastro/.github/blob/main/COMMUNITY_GUIDE.md
|
|
36
|
+
[discord]: https://astro.build/chat/
|
|
37
|
+
[issues]: https://github.com/withastro/language-tools/issues
|
|
38
|
+
[astro-integration]: https://docs.astro.build/en/guides/integrations-guide/
|
package/dist/index.js
CHANGED
|
@@ -28,9 +28,7 @@ export async function check(flags) {
|
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
// Dynamically get the list of extensions to watch from the files already included in the project
|
|
31
|
-
const checkedExtensions = Array.from(new Set(checker.linter.
|
|
32
|
-
.typescript.projectHost.getScriptFileNames()
|
|
33
|
-
.map((fileName) => path.extname(fileName))));
|
|
31
|
+
const checkedExtensions = Array.from(new Set(checker.linter.projectHost.getScriptFileNames().map((fileName) => path.extname(fileName))));
|
|
34
32
|
createWatcher(workspaceRoot, checkedExtensions)
|
|
35
33
|
.on('add', (fileName) => {
|
|
36
34
|
checker.linter.fileCreated(fileName);
|
package/package.json
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@astrojs/check",
|
|
3
|
-
"
|
|
3
|
+
"description": "Type checking and diagnostics for Astro projects",
|
|
4
|
+
"version": "0.8.0",
|
|
4
5
|
"author": "withastro",
|
|
5
6
|
"license": "MIT",
|
|
7
|
+
"homepage": "https://github.com/withastro/language-tools/tree/main/packages/astro-check",
|
|
6
8
|
"repository": {
|
|
7
9
|
"type": "git",
|
|
8
10
|
"url": "https://github.com/withastro/language-tools",
|
|
@@ -20,7 +22,7 @@
|
|
|
20
22
|
"dist/**/*.d.ts"
|
|
21
23
|
],
|
|
22
24
|
"dependencies": {
|
|
23
|
-
"@astrojs/language-server": "^2.
|
|
25
|
+
"@astrojs/language-server": "^2.11.0",
|
|
24
26
|
"chokidar": "^3.5.3",
|
|
25
27
|
"fast-glob": "^3.3.1",
|
|
26
28
|
"kleur": "^4.1.5",
|