Skip to content

feat: expose style dependencies and buildFinished events - #14

Closed
davidpett wants to merge 1 commit into
stencil-community:mainfrom
davidpett:feat/style-deps-and-build-events
Closed

davidpett wants to merge 1 commit into
stencil-community:mainfrom
davidpett:feat/style-deps-and-build-events

Conversation

@davidpett

Copy link
Copy Markdown
Collaborator

Summary

  • Rename package to @stencil-community/unplugin-stencil and update README install/import references.
  • Add getComponentStyleDependencies() returning byComponent, byStyle, and resolved globalStyle maps, rebuilt after each successful Stencil compile via TypeScript AST over component sources (styleUrl, styleUrls array, and mode object).
  • Add stencilBuildEvents (buildFinished with CompilerBuildResults, buildError) forwarded from BuildQueue so consumers can invalidate all dist output after a project-wide rebuild without mtime polling.
  • Add typescript as a runtime dependency for AST parsing.
  • Update release workflow: bump actions/checkout and pnpm/action-setup to v4, use a generic GitHub Actions git identity, and enable npm provenance.

Motivation

Enables @stencil/storybook-plugin (and similar tooling) to drop fragile regex extraction of style paths and post-transform dist polling.

Test plan

  • pnpm exec vitest run test/ (19 tests pass)
  • pnpm build

Add getComponentStyleDependencies() for component/style file graphs and
stencilBuildEvents so downstream tools can react after project-wide Stencil
rebuilds without regex or dist mtime polling.
@davidpett
davidpett force-pushed the feat/style-deps-and-build-events branch from f644074 to f74c494 Compare June 10, 2026 22:50
@davidpett

Copy link
Copy Markdown
Collaborator Author

Closing — superseded by #15 which rebases cleanly on top of the merged main.

@davidpett davidpett closed this Jun 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant