diff --git a/branch/latest/md5.js b/branch/latest/md5.js index 0baa6e6..cbda434 100644 --- a/branch/latest/md5.js +++ b/branch/latest/md5.js @@ -1,7 +1,8 @@ // let document = document; // let window = window; -'use strict'; +// 'use strict'; +// 兼容nodejs, 要不然 window = {}; 会崩 let name_input = "test\ntest2"; let assets_data = { @@ -10,9 +11,13 @@ let assets_data = { }; let run_env = { - + from_code: (typeof window == "undefined"), + is_node: (typeof Bun == "undefined"), + is_bun: (typeof Bun != "undefined"), }; +console.log("run_env", run_env); + let from_code = typeof window == "undefined";