Package Exports
- @stacksjs/collections
- @stacksjs/collections/dist/index.mjs
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@stacksjs/collections) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Stacks Collections
Easily work with via Laravel-like collections.
☘️ Features
- Access to Laravel-like Collections API
- Other object helpers
🤖 Usage
pnpm i -D @stacksjs/collectionsNow, you can easily access it in your project:
import { collect } from '@stacksjs/collections'
const collection = collect([{
name: 'My story',
pages: 176,
}, {
name: 'Fantastic Beasts and Where to Find Them',
pages: 1096,
}])
console.log(collection.avg('pages')) // 636To view the full documentation, please visit https://stacksjs.dev/collections.
🧪 Testing
pnpm test📈 Changelog
Please see our releases page for more information on what has changed recently.
💪🏼 Contributing
Please see CONTRIBUTING for details.
🏝 Community
For help, discussion about best practices, or any other conversation that would benefit from being searchable:
For casual chit-chat with others using this package:
Join the Open Web Discord Server
🙏🏼 Credits
Many thanks to the following core technologies & people who have contributed to this package:
📄 License
The MIT License (MIT). Please see LICENSE for more information.
Made with ❤️