Skip to content

Commit

Permalink
v0.10.0
Browse files Browse the repository at this point in the history
* fix(core): use native functionality in place of lodash methods
* fix(core): add `eslint-plugin-jsdoc` to confirm that valid jsdoc comments are included
* fix(orderedReducer): remove subcollection merging logic to fix removing of value for `DOCUMENT_MODIFIED` action type - #243, #140  
* feat(query): show console error if `subcollections` are passed without `storeAs` - subcollection merging support is being removed in preparation for [v1](https://github.com/prescottprue/redux-firestore/wiki/v1.0.0-Roadmap) (which stores all subcollections at the top level)
* fix(examples): update basic and complete examples - #242 
* chore(tests): add test for deleted values from arrays within documents - #140, #243 
* chore(tests): add test for `collectionGroup`
  • Loading branch information
prescottprue authored Nov 6, 2019
1 parent 78cb846 commit 06e4bb4
Show file tree
Hide file tree
Showing 126 changed files with 25,796 additions and 43,827 deletions.
18 changes: 15 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,38 @@ module.exports = {
'extends': [
'airbnb-base',
'google',
'prettier'
'prettier',
'plugin:jsdoc/recommended'
],
plugins: [
'babel',
'prettier'
'prettier',
'jsdoc'
],
env: {
browser: true,
es6: true,
node: true
},
settings: {
'import/resolver': {
node: {
moduleDirectory: ['node_modules', '/']
}
}
},
rules: {
'prettier/prettier': ['error', {
'singleQuote': true,
'trailingComma': 'all'
}],
'no-console': 'error',
'valid-jsdoc': 0, // from google
'no-confusing-arrow': 0,
'no-case-declarations': 0,
'arrow-parens': [2, 'as-needed'],
'prefer-default-export': 0
'prefer-default-export': 0,
'jsdoc/newline-after-description': 0,
'jsdoc/no-undefined-types': [1, { definedTypes: ['firebase'] }]
}
}
11 changes: 8 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -275,11 +275,16 @@ store.firestore.unsetListeners([query1Options, query2Options]),
##### Sub Collections

```js
{ collection: 'cities', doc: 'SF', subcollections: [{ collection: 'zipcodes' }] },
// or string equivalent
// props.store.firestore.get('cities/SF'/zipcodes),
{
collection: 'cities',
doc: 'SF',
subcollections: [{ collection: 'zipcodes' }],
storeAs: 'SF-zipcodes' // make sure to include this
},
```

**NOTE**: `storeAs` is now required for subcollections. This is to more closley match the logic of [the upcoming major release (v1)](https://github.com/prescottprue/redux-firestore/wiki/v1.0.0-Roadmap) which stores all collections, even subcollections, at the top level of `data` and `ordered` state slices.

##### Collection Group
```js
{ collectionGroup: 'landmarks' },
Expand Down
1 change: 1 addition & 0 deletions examples/basic/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SKIP_PREFLIGHT_CHECK=true
2 changes: 1 addition & 1 deletion examples/basic/jsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
},
"exclude": [
"node_modules",
"public",
"public"
]
}
Loading

0 comments on commit 06e4bb4

Please sign in to comment.