Git Product home page Git Product logo

js-storage's People

Contributors

increddibelly avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

js-storage's Issues

Possibility to add js-storage to mvnrepository.com or create a webjar

Hi. I would like to ask if there's a possibility to add this plugin to maven repository to achieve easily access to it? I also tried to create a webjar, but there was an error due to some license issues. The error communicate I got is below.

Got package info for org.webjars.bowergithub.julien-maurel js-storage 1.0.4
Determining dependency graph
No dependencies.
Resolving licenses & dependencies for org.webjars.bowergithub.julien-maurel js-storage 1.0.4
All attempts to determine an acceptable license have been exhausted. The bower.json file did not contain a spec-compliant license definition and the license could not be determined by trolling through the source repo: https://github.com/julien-maurel/js-storage.git
The acceptable open source software licenses are at bottom of: https://bintray.com/docs/api/
The provided licenses were:
This problem will likely need to be resolved by working with the library maintainers directly.

Regards,
Kamil

How to set array storage

how can i set() proses_send value in this my data array ?

{
  "status": [
    {
      "waybill_number": "1234567890",
      "jml_hawb": 3500,
      "proses_send": 3012,
      "siap_send": 488,
      "finish_send": 0
    },
    {
      "waybill_number": "9999999999",
      "jml_hawb": 1000,
      "proses_send": 1000,
      "siap_send": 0,
      "finish_send": 0
    }
  ]
}

I have tried ns.sessionStorage.set('status[0].siap_send',33333) but this makes new data

`{
  "status": [
    {
      "waybill_number": "1234567890",
      "jml_hawb": 3500,
      "proses_send": 3013,
      "siap_send": 487,
      "finish_send": 0
    },
    {
      "waybill_number": "9999999999",
      "jml_hawb": 1000,
      "proses_send": 1000,
      "siap_send": 0,
      "finish_send": 0
    }
  ],
  "status[0]": {
    "siap_send": 33333
  }
}

Cannot store simple elements (Waidw ?)

Hi,
i'm quite new to the local storage feature, so i tried out your lib which works good for simple values.
When i want to store an element, it get serialized to JSON but wrong.
Consider this example:
// initialize the new HTML elements
var tabSpan = $('', {
html: 'Message Center'
});
var messageCenterAnchor = $('', {
href: '/user/messages',
html: tabSpan
});
var newListItem = $('

  • ', {
    html: messageCenterAnchor,
    class: 'notification'
    });

    Then i do:
    storage.set('notification-value-0, newListItem );

    Stored will be:
    key: 'notification-value-0 value: {0":{},"length":1}

    I read about disabling automatic JSON rendering, but failed.
    Always the same outcome.

    Perhaps you've a clue how i can store elements.

    Rgds.
    Franz

  • Getting nested value of null

    When I try to get config.item I get "Uncaught TypeError: Cannot read property 'item' of null".

    This should return null/undefined and init default value for config item instead of throwing an exception.

    Example:

    if(!this.storage.get('config') {
        this.storage.set('config', {});
    }
    

    Remove from all storage types by regex

    First of all, Great library. Thanks

    I faced with need that for example I need to remove all key, which starts with "payment"
    For this I used next code cookies.remove(cookies.keys().filter((key) => key.startsWith('payment')));
    But it is not efficient one... Why not to use this one with regex in you library?
    For your discretion

    Cookie storage is missing secure flag

    Hopefully I dont get it wrong, but it seems there is no support for the secure flag on cookie storage.

    So, the request is to extend the cookie storage handling by the secure flag.

    Error when using expiration plugin

    Error message:
    Uncaught TypeError: t.charCodeAt is not a function -> store.everything.min.js?v=9609:2

    Using in a bootstrap jquery project like this:

    <script src="./node_modules/store/dist/store.everything.min.js"></script>
    <script src="./js/app.js"></script>
    

    Script:

    var data = {lon: -666, lat: -666, key: 666};
    store.set('weather', data, new Date().getTime() + 3000); // expiration in 3 sec
    

    Comprehensive Tutorial on Namespace

    In your read Me can you please elaborate on how to use namespace. An example on how to set and get values with namespace and perform various operations will be appreciated.
    I followed the examples and understand the localstorage but how to integrate the namespace is little bit confusing. Thanks.

    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.