-2
Daily
+18
Weekly
+44
Monthly
32,022
stars
1,418
forks
218
watchers
1,142
prs
641
issues
160
releases
README
Alpine.js Go to the Alpine docs for most things: Alpine Docs You are welcome to submit updates to the docs by submitting a PR to this repo. Docs are located in the /packages/docs directory. Stay here for contribution-related information. Looking for V2 docs? here they are Contribution Guide: Quickstart clone this repo locally run npm install & npm run build Include the /packages/alpinejs/dist/cdn.js file from a tag on a webpage and you're good to go! Brief Tour You can get everything installed with: npm install in the root directory of this repo after cloning it locally. This repo is a "mono-repo" using npm workspaces for managing the packages. Each package has its own folder in the /packages directory. Rather than having to run separate builds for each package, all package bundles are handled with the same command: npm run build Here's a brief look at each package in this repo: Package | Description --- | --- alpinejs | The main Alpine repo with all of Alpine's core collapse | A plugin for expanding and collapsing elements using smooth animations csp | A repo to provide a "CSP safe" build of Alpine docs | The Alpine documentation focus | A plugin that allows you to manage focus inside an element history | A plugin for binding data to query string parameters using the history API (name is likely to change) intersect | A plugin for triggering JS expressions based on elements intersecting with the viewport mask | A plugin for automatically formatting a text input field as a user types morph | A plugin for morphing HTML (like morphdom) inside the page intelligently persist | A plugin for persisting Alpine state across page loads The compiled JS files (as a result of running npm run [build/watch]) to be included as a tag for example are stored in each package's packages/[package]/dist directory. Each package should at least have: a "cdn" build that is self-initializing and can be included using the src attribute in a tag, and a module.[esm/cjs].js file that is used for importing as a JS module (cjs for node, esm for everything else). The bundling for Alpine V3 is handled exclusively by ESBuild. All of the configuration for these builds is stored in the scripts/build.js file. Testing There are 2 different testing tools used in this repo: Cypress (for integration tests), and Vitest (for unit tests). All tests are stored inside the /tests folder under /tests/cypress and /tests/vitest. If you wish to only run Cypress and open it's user interface (recommended during development), you can run: npm run cypress If you wish to only run Vitest tests, you can run npm run vitest like normal and target specific tests.
Top issues
#4928x-modelable loses a change made right after a morph, and leaks a binding on every morph1 comments · 2026-10-08#4947@alpinejs/csp: global scan triggers "Fenced Frame API is deprecated" in Chrome / Lighthouse0 comments · 2026-11-13#4944@alpinejs/csp: ++ on string values concatenates ("5" -> "51") instead of incrementing0 comments · 2026-11-07#4943@alpinejs/csp strips the backslash from \xXX, \u{...}, \b, \f, \v, and \0 string escapes0 comments · 2026-11-07#4933x-data reconciliation (#4868) evaluates old getters without parent scope; a throw leaves the component without its scope0 comments · 2026-10-16#4911x-for reorders nested templates incorrectly0 comments · 2026-09-19#4894Wrong logo on website /logo.svg0 comments · 2026-09-04#4885Forced `x-model` select sync displays the first option when the model matches no option (dependent selects; regression in `3.16.0` via #4769)0 comments · 2026-08-27
Discussions
#4919Custom objects implementing the EventTarget interface lose reactivity of their properties1 comments · 2026-09-24#4860IndexedDB support for Persist plugin1 comments · 2026-07-21#4857Component support feature1 comments · 2026-07-19#4854Alpine.js + Complex State Management: When does it make sense to switch to a framework?3 comments · 2026-07-04#4850TanStack Alpine libraries1 comments · 2026-06-29#4847x-for and x-sort not working in FiveM CEF browser2 comments · 2026-06-20#4845With the new `navigation.navigate`, the way for bigger SPA is open0 comments · 2026-06-14#4841Encapsulating directives with x-bind and $el1 comments · 2026-06-08
Latest release
v3.17.5 v3.17.5 2026-10-20What's Changed Don't re-apply x-cloak to rendered elements during morph by @calebporzio in https://github.com/alpinejs/alpine/pull/4922 Full Changelog: https://github.com/alpinejs/alpine/compare/v3.17.4...v3.17.5