diff --git a/packages/collections/CHANGELOG.md b/packages/collections/CHANGELOG.md index 335174dec..ec111892e 100644 --- a/packages/collections/CHANGELOG.md +++ b/packages/collections/CHANGELOG.md @@ -1,5 +1,11 @@ # @openfn/language-collections +## 0.7.1 + +### Patch Changes + +- Fixed some small issues in the docs + ## 0.7.0 ### Minor Changes diff --git a/packages/collections/package.json b/packages/collections/package.json index 896d12e86..06e4cb777 100644 --- a/packages/collections/package.json +++ b/packages/collections/package.json @@ -1,6 +1,6 @@ { "name": "@openfn/language-collections", - "version": "0.7.0", + "version": "0.7.1", "description": "OpenFn collections adaptor", "type": "module", "exports": { diff --git a/packages/collections/src/collections.js b/packages/collections/src/collections.js index 79f580d57..7422d757d 100644 --- a/packages/collections/src/collections.js +++ b/packages/collections/src/collections.js @@ -53,7 +53,7 @@ export const setMockClient = mockClient => { * @example Get a range of values from a collection with a key pattern * collections.get('my-collection', '2024*') * @example Get all values created since the end of January 2024 - * collections.get('my-collection', { createdAfter: '202401') + * collections.get('my-collection', { createdAfter: '202401'}) */ export function get(name, query = {}) { return async state => { @@ -126,6 +126,7 @@ export function get(name, query = {}) { * a string key. * @public * @function + * @param {string} name - The name of the collection to fetch from * @param keygen - a function which generates a key for each value: (value, index) => key. Pass a string to set a static key for a single item. * @param values - an array of values to set, or a single value. * @example Set a number of values using each value's id property as a key @@ -133,7 +134,7 @@ export function get(name, query = {}) { * @example Set a number of values, generating an id from a string template * collections.set('my-collection', (item) => `${item.category}-${Date.now()}`, $.data) * @example Set a single value with a static key - * collections.set('my-collection', 'city-codes', { NY: 'New York', LDN: 'London' }}) + * collections.set('my-collection', 'city-codes', { NY: 'New York', LDN: 'London' }) */ export function set(name, keyGen, values) { let argCount = arguments.length; @@ -238,7 +239,7 @@ export function set(name, keyGen, values) { * @example Remove a range of values from a collection with a key pattern * collections.remove('my-collection', '2024*') * @example Remove all values created since the end of January 2024 - * collections.remove('my-collection', { createdAfter: '202401') + * collections.remove('my-collection', { createdAfter: '202401'}) */ export function remove(name, query = {}, options = {}) { return async state => {