https://github.com/codenoid/slicey
Spicy slice in Go, collection of slice modifier
https://github.com/codenoid/slicey
array slice slice-modifier
Last synced: 8 months ago
JSON representation
Spicy slice in Go, collection of slice modifier
- Host: GitHub
- URL: https://github.com/codenoid/slicey
- Owner: codenoid
- Created: 2020-01-15T14:39:42.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-01-15T16:18:41.000Z (about 6 years ago)
- Last Synced: 2025-03-28T15:48:20.794Z (11 months ago)
- Topics: array, slice, slice-modifier
- Language: Go
- Size: 2.93 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Slicey
Collection of slice modifier in Golang (Go)
## Install
```bash
go get -u github.com/codenoid/slicey
```
## Usage
```go
bigSlice := []interface{}{"a", "b", "c", ".... so on"}
splitted := slicey.Splitl(bigSlice, 13)
c := make(chan bool)
for _, child := range splitted {
// len(splitted) goroutine
go DoTheJob(child, c)
}
var chans [len(splitted)]bool
for i := range chans {
chans[i] = <- c
}
```
## Features
- [x] Split left
- [x] Split fill all
- [ ] Value sorting
- [ ] Auto split dynamically
- [ ] [Request feature](https://github.com/codenoid/slicey/issues)