Storage read write special chars åäö

Hi, I’m trying to write with storage:

function write(){
  data = {"åäö":"åäö"};
  data = JSON.stringify(data);
  Storage.write("test.txt", data);

function read(){"test.txt").then(function(content) {      console.log(content); // {"åäö":"å


// next time app start user read();

It will output {"åäö":"å and NOT {"åäö":"åäö"}

Anyone have an idea?

Those methods are async. So you are reading the file before it is done writing. You could either rewrite your code to run synchronous:

Storage.writeSync("test.txt", data);

Or you could read the file after the write completes like this:

Storage.write("test.txt", data).then(function(wasSuccess) {
    if(wasSuccess) {"test.txt").then(function(content) {          console.log(content);

But I still get {"åäö":"å insted of {"åäö":"åäö"} ?

I will take a look.

What is the target/platform you are running?

If you’re on Windows this is probably due to the unicode bug that was reported before:

This will be fixed in Fuse 0.9.11.