UI components for Hypothesis front-end applications.
Your project must have preact
and tailwindcss
as dependencies.
$ yarn add preact tailwindcss
$ yarn add @hypothesis/frontend-shared
Update your project's tailwind configuration:
import tailwindConfig from '@hypothesis/frontend-shared/lib/tailwind.preset.js';
export default {
// Use this package's preset
presets: [tailwindConfig],
content: [
// Be sure to add this project's component source to your
// tailwind content globs
'./node_modules/@hypothesis/frontend-shared/lib/**/*.{js,ts,tsx}',
],
// ...
Full documentation is available in this project's web-based pattern library.
- Run the local web server:
$ make dev
- Visit http://localhost:4001/ in a browser
import { Link } from '@hypothesis/frontend-shared';