We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
const fs=require('node:fs') const files = fs.readdirSync('./'); const filePath = './newFile.txt'; fs.writeFile(filePath, '这是新文件的内容', (err) => { if (err) { console.error('文件创建时发生错误:', err); } else { console.log('文件创建成功!'); } }); fs.unlink(filePath, (err) => { if (err) { console.error('删除文件时出错:', err); } else { console.log('文件删除成功!'); } });
我发现fs可以创建成功文件,并且可以删除文件,能否配置javet的访问权限,例如不允许删除文件
The text was updated successfully, but these errors were encountered:
You may pass console arguments to Node.js. This is the standard way. Javet doesn't make changes to the Node.js source code.
Sorry, something went wrong.
No branches or pull requests
const fs=require('node:fs')
const files = fs.readdirSync('./');
const filePath = './newFile.txt';
fs.writeFile(filePath, '这是新文件的内容', (err) => {
if (err) {
console.error('文件创建时发生错误:', err);
} else {
console.log('文件创建成功!');
}
});
fs.unlink(filePath, (err) => {
if (err) {
console.error('删除文件时出错:', err);
} else {
console.log('文件删除成功!');
}
});
我发现fs可以创建成功文件,并且可以删除文件,能否配置javet的访问权限,例如不允许删除文件
The text was updated successfully, but these errors were encountered: