mirror of
https://github.com/wekan/wekan.git
synced 2025-12-24 03:10:12 +01:00
Fixed Non-ASCII attachment filename will crash when downloading.
Thanks to xet7 ! Fixes #2759
This commit is contained in:
parent
843ff8eaaa
commit
c2da477735
277 changed files with 30568 additions and 52 deletions
82
packages/wekan-cfs-reactive-list/README.md
Normal file
82
packages/wekan-cfs-reactive-list/README.md
Normal file
|
|
@ -0,0 +1,82 @@
|
|||
wekan-cfs-reactive-list [](https://travis-ci.org/CollectionFS/Meteor-reactive-list)
|
||||
=========
|
||||
|
||||
~~Looking for maintainers - please reach out!~~
|
||||
This package is to be archived due to inability to find contributors, thanks to everyone who helped make it possible.
|
||||
|
||||
**If you're looking for an alternative, we highly recommend [Meteor-Files](https://github.com/VeliovGroup/Meteor-Files) by [VeliovGroup](https://github.com/VeliovGroup)**
|
||||
|
||||
---
|
||||
|
||||
ReactiveList keeps a sortable reactive list of key+value items. It's simple and fast.
|
||||
|
||||
And... It's powered by Meteor's reactive sugar :)
|
||||
|
||||
Kind regards,
|
||||
Eric (@aldeed) and Morten (@raix)
|
||||
|
||||
Happy coding!!
|
||||
|
||||
#API
|
||||
[API Documentation](api.md)
|
||||
|
||||
From the docs:
|
||||
#### <a name="ReactiveList"></a>new ReactiveList([options], sort) <sub><i>Anywhere</i></sub> ####
|
||||
-
|
||||
|
||||
__Arguments__
|
||||
|
||||
* __options__ *{object}* (Optional)
|
||||
* __sort__ *{function}*
|
||||
The sort algorithm to use
|
||||
|
||||
-
|
||||
Example:
|
||||
```js
|
||||
var list = new ReactiveList();
|
||||
list.insert(1, { text: 'Hello id: 1' });
|
||||
list.insert(2, { text: 'Hello id: 2' });
|
||||
list.insert(3, { text: 'Hello id: 3' });
|
||||
list.update(2, { text: 'Updated 2'});
|
||||
list.remove(1);
|
||||
|
||||
list.forEach(function(value, key) {
|
||||
console.log('GOT: ' + value.text);
|
||||
}, true); // Set noneReactive = true, default behaviour is reactive
|
||||
// Return from Template:
|
||||
Template.hello.list = function() {
|
||||
return list.fetch();
|
||||
};
|
||||
```
|
||||
|
||||
#### Example of a sort algorithm
|
||||
Sort can be used to define the order of the list
|
||||
```js
|
||||
var list = new ReactiveList({
|
||||
sort: function(a, b) {
|
||||
// a and b are type of { key, value }
|
||||
// here we sort by the key:
|
||||
return a.key < b.key;
|
||||
}
|
||||
});
|
||||
```
|
||||
### Object chain
|
||||
```
|
||||
first last
|
||||
undefined - obj - obj - obj - undefined
|
||||
(prev value next) (prev value next) (prev value next)
|
||||
```
|
||||
|
||||
```
|
||||
ReactiveList = function(options) { ...
|
||||
```
|
||||
|
||||
See more at [reactive-list.js:46](reactive-list.js#L46).
|
||||
|
||||
# Contribute
|
||||
|
||||
Here's the [complete API documentation](internal.api.md). To update the docs, run `npm install docmeteor`, then
|
||||
|
||||
```bash
|
||||
$ docmeteor
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue