About Lemon.js
Lemon.js is a lightweight JavaScript library (2.3kB) that seamlessly integrates Lemon Squeezy functionality into your application, allowing you to effortlessly open checkout overlays and more.
Installation
You can get started using Lemon.js by embedding our tiny (2.3kB) library via our CDN into the head
or body
of your page.
By default, any anchor tag <a>
on the page with the class lemonsqueezy-button
assigned will, when clicked, open a Lemon Squeezy link. This makes it easy to open a Lemon Squeezy checkout overlay without having to write any JavaScript.
Please don’t self-host Lemon.js, you may miss out on new features and important security patches.
Advanced usage
As a developer, you may want to tightly integrate Lemon Squeezy within the various flows of your application, such as during the registration process.
Lemon.js exposes optional functionality you can use within your application: