JSON.stringify that can write any javascript code to the file.