Skip to content

Add type declaration #118

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

Merged
merged 2 commits into from
May 18, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
update types
- This way it doesn't rely on the `@types/tailwindcss` Definetely Typed
  repo which could cause issues when we release Tailwind CSS 3.1 with
  our own types.
- Use `export = plugin` instead of `export default plugin` so that it is
  compatible with `module.export`
  • Loading branch information
RobinMalfait committed May 18, 2022
commit 1336243b4f616e79b7b929cb7b8a7ffe0a5338d3
6 changes: 2 additions & 4 deletions src/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
import { TailwindPluginWithOptionsFn } from 'tailwindcss/plugin'

declare const plugin: TailwindPluginWithOptionsFn<{ strategy?: 'base' | 'class' }>
export default plugin
declare function plugin(options?: { strategy?: 'base' | 'class' }): Function
export = plugin