endea
v0.1.11
Published
A zero-config, type-safe fetch simulator for TypeScript & JavaScript
Maintainers
Readme
⚡ Endea
A zero-config, type-safe fetch simulator for TypeScript & JavaScript
🚀 What is Endea?
Endea is a fake fetch that feels real.
Instead of waiting for a backend, you generate realistic async responses directly in your code:
const users = await endea<User>({ name: "John", age: 30 }, { count: 50 });No API. No setup. No stress.
✨ Features
- Async like fetch — just await
- Type-safe — powered by TypeScript generics
- Zero config — install and go
- Realistic data — powered by Faker
- Simulate APIs — delay, errors, bulk data
📦 Installation
npm install endeaUsage
Basic Example
import { endea } from "endea";
type User = {
name: string;
age: number;
};
const users = await endea<User>({ name: "John", age: 30 }, { count: 3 });
console.log(users);⚙️ Advanced Options
const users = await endea<User>(
{ name: "John", age: 30 },
{
count: 50,
delay: 500,
errorRate: 0.1,
},
);🧠 How It Works
- Reads your input shape
- Infers types automatically
- Uses Faker to generate realistic values
- Wraps everything in a Promise
🧩 Use Cases
- 🚧 Frontend development without APIs
- 🧪 UI testing with realistic and flexible data
- ⚡ Rapid prototyping
- 🎯 Error + latency simulation
⚠️ Notes
[!IMPORTANT] Endea currently runs in local mode only (no backend required).
[!TIP] Keep your initial object realistic — it improves generated data quality.
🔮 Roadmap
- Backend integration (type serialization)
- Custom generators
- Plugin system
- Devtools integration
🛠️ Built With
- Faker.js (for realistic data generation)
🤝 Contributing
PRs are welcome. Open an issue first to discuss changes.
📄 License
MIT © Jeremiah Ndiritu GitHub: https://github.com/jeremiah-ndiritu/endea
💬 Final Thought
What if fetch worked… even when your API doesn’t exist yet? That’s Endea.
