Giter VIP home page Giter VIP logo

Comments (6)

WebReflection avatar WebReflection commented on June 28, 2024

the Chrome is using the WebSQL database and the fact you have multiple db
in your debugger does not mean it creates multiple databases :-)

Data is persistent indeed and the API used behind the scene is
openDatabase, not createDatabase.

The db.create() name might mislead but you can consider it the equivalent
of db.open() where if the db is not there, it's created.

Maybe I'll simply alias .create() with .open()

Anyway, if you close the debugger and reopen again you'll see only one
instance of the database ;-)

hope this helps

On Tue, Jul 3, 2012 at 12:08 PM, noiv <
[email protected]

wrote:

Hi,

i have the lib in use in development and it works good. However, one thing
makes me wondering, maybe I missed an essential part of the docs. On each
(re-)load 'asyncStorage.create(dbName, function(mydb){...' is executed and
leads to multiple entries of dbName in Chrome/Resources/Database. Currently
I keep overall size of values stored low, so it will fit in a cookie as
last resort.

But wouldn't these multiple entries effect maximum storage size?


Reply to this email directly or view it on GitHub:
#1

from db.

noiv avatar noiv commented on June 28, 2024

Thanks, for the explanation, was just a semantic issue :) . No need to change working code.

from db.

jfktrey avatar jfktrey commented on June 28, 2024

I was confused about this, too. The documentation doesn't really make this clear and the fact that multiple databases show up in Chrome adds to the confusion. A quick clarification in the readme would be great.

from db.

WebReflection avatar WebReflection commented on June 28, 2024

a clarification in Chrome developers tool ? sure it would be appreciated … since it has nothing to do with db, right?

from db.

jfktrey avatar jfktrey commented on June 28, 2024

Right, I meant to say the fact that create() also opens databases.

from db.

WebReflection avatar WebReflection commented on June 28, 2024

so you are suggesting that aliasing it would make more sense? db.open() as alias of db.create() … might do that :-)

from db.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.