@gn8/alien-signals-svelte
v0.1.1
Published
The alien-signals for Svelte.
Maintainers
Readme
alien-signals for Svelte
A library that enables the use of the alien-signals state management system in Svelte 5+ with runes.
🛸 Features
- Simple: Easy to implement with minimal code
- Flexible: Reuse a single signal across multiple frameworks
- Type Safe: Full TypeScript support
- Best Reactivity: Leverages alien-signals efficient signal management
- Tree Shakable: Bundle only the code you need
- Runes Support: Native integration with Svelte 5's runes system
🔌 Status
| Framework | Status | SSR Support | Repo | | --------- | ------ | ----------- | ----------------------------- | | React | ✅ | 🔼 | 🔗 | | Solid | ✅ | 🔼 | 🔗 | | Vue | ✅ | 🔼 | 🔗 | | Svelte | ✅ | 🔼 | 🔗 |
- ✅: Implemented
- 🔼: Avoidable
- ⚠️: Unverified
- ⌛️: Coming Soon
💻 Guide
Installation
npm install alien-signals @gn8/alien-signals-svelteSample Code
<script>
import { useSignal } from '@gn8/alien-signals-svelte';
import { signal } from 'alien-signals';
const countSignal = signal(0);
const count = useSignal(countSignal);
</script>
<button on:click={() => $count++}>
count is {$count}
</button>Examples
- Svelte (Coming Soon)
📚 Roadmap
The following features and support will be added sequentially:
- [ ] Documentation and solutions for handling SSR hydration errors
- [ ] Enhancement of test coverage
- [ ] Creation of Svelte 5 usage examples
- [ ] Integration with SvelteKit
🙏 Acknowledgments
The development of this library was influenced by:
- alien-signals - The core signal library
- Svelte - The progressive JavaScript framework
