Extensions Developer Guide
Welcome to the Extensions Developer guide!
- Key Concepts
- Developing your Extension
- Tutorials
- API Reference
- Discourse Category
- Publish your Extension
- Frequently Asked Questions
Templates
React Extension Template
A starter template for building Extensions with the React Client.
HTML/CSS/JS Extension Template
A starter template for building Extensions with HTML, CSS, and Javascript.
Installation
HTML/CSS/JS
Start using the Extensions API client by inserting this code into the <head>
tag of your HTML:
<script src="https://unpkg.com/@replit/extensions@1.0.0-beta.0/dist/index.global.js"></script>
Start using the API client by creating a new <script>
tag and using the pre-defined replit
variable.
<script>
async function main() {
await replit.init();
...
}
window.addEventListener('load', main);
</script>
Module Import
If you are using a framework that supports module import resolution, install the client with your preferred package manager and use the import
statement to start using it.
npm install @replit/extensions
yarn add @replit/extensions
pnpm add @replit/extensions
After installing the API client, use the import
statement to start using it.
import {
fs,
data,
...
} from '@replit/extensions';
Feedback & Support
The best way to get support and/or give us your feedback on Extension Development is to post on the Ask Forum's Extensions category.