writeFile new line

I am using file plugin from ionic native
i want to make a new line before adding the new input
this.file.writeFile(this.file.externalRootDirectory, ‘mydir.txt’,this.dateForDisplay,{ replace: false, append: true });
how i can do that

thank you at advance

this.file.writeFile(this.file.externalRootDirectory, 'mydir.txt',this.dateForDisplay+"\n",{ replace: false, append: true });

That is the solution?

yes this is the solution

1 Like