-
-
Notifications
You must be signed in to change notification settings - Fork 13
feat: support tsconfig paths #185
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds support for TypeScript config path resolution in Tailwind CSS configurations by introducing a tsconfig
option to settings and rules. This enables the plugin to resolve path aliases defined in TypeScript configuration files when processing imports and module resolution.
- Adds
tsconfig
configuration option to all rules and global settings - Implements TypeScript path resolution using the
tsconfig-paths-webpack-plugin
- Refactors the async context system to support unified configuration and warning handling
Reviewed Changes
Copilot reviewed 62 out of 63 changed files in this pull request and generated 4 comments.
Show a summary per file
File | Description |
---|---|
src/types/async.ts | Moves Warning interface to centralized async types |
src/utils/options.ts | Adds tsconfig option to common options handling |
src/async-utils/context.ts | Creates unified async context management system |
src/async-utils/tsconfig.ts | Implements TypeScript config path resolution |
src/async-utils/resolvers.ts | Updates resolvers to support TypeScript path mapping |
src/tailwindcss/*.ts | Updates all Tailwind modules to use new async context system |
src/rules/*.ts | Adds tsconfig option to all rule configurations |
package.json | Adds tsconfig-paths-webpack-plugin dependency |
docs/ | Updates documentation for new tsconfig option |
|
||
runAsWorker(async ({ classes, configPath }: GetDissectedClassRequest) => { | ||
const context = await createTailwindContext(configPath); | ||
return getDissectedClasses(context, classes); | ||
runAsWorker(async ({ classes, configPath, cwd, tsconfigPath }: GetDissectedClassRequest) => { |
Copilot
AI
Jul 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing return type annotation and response structure. The function should return GetDissectedClassResponse
but only returns the raw dissected classes array.
Copilot uses AI. Check for mistakes.
closes: #121
TODO:
tsconfig
option to settings and rules.