Closed Tobino closed 7 years ago
@Tobino I don't really get what the first example-code does/should do. Can you make an example where rxdb is involved and how you insert/fetch documents?
Example with rxdb :
var mySchema = {
title: 'hero schema',
description: 'describes a simple hero',
type: 'object',
properties: {
likes: {
type: 'array',
items: {
type: 'string'
}
}
}
};
RxDB.create('heroesDB', 'fruitdown') // create database
.then(function (db) { return db.collection('mycollection', mySchema); }) // create collection
.then(function (collection) {
collection.insert({likes: ['abc', '8']});
collection
.find()
.$ // <- returns observable of query
.subscribe(docs => {
if (docs) {
console.dir(docs);
}
});
});
And console.dir
{
likes: [
{0:'a',1:'b',2:'c'},
{0:'8'}
]
}
Do you think fruitdown could be involved ?
Fixed with this PR.
Fixed in version 2.0.4. Please upgrade.
Hi everyone,
When we are using an array of string, RXDB's collection return a wrong array.
Example:
while we are expecting the same array.
example of schema: