ventojs 0.9.2 → 0.10.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/deps/deno.land/std@0.210.0/assert/assert.d.ts +12 -0
- package/esm/deps/deno.land/std@0.210.0/assert/assert.js +18 -0
- package/esm/deps/deno.land/std@0.210.0/assert/assertion_error.d.ts +14 -0
- package/esm/deps/deno.land/std@0.210.0/assert/assertion_error.js +18 -0
- package/{script/deps/deno.land/std@0.208.0 → esm/deps/deno.land/std@0.210.0}/path/_common/glob_to_reg_exp.d.ts +1 -0
- package/esm/deps/deno.land/std@0.210.0/path/common.d.ts +13 -0
- package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/extname.js +1 -1
- package/{script/deps/deno.land/std@0.208.0 → esm/deps/deno.land/std@0.210.0}/path/mod.d.ts +2 -2
- package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/mod.js +3 -1
- package/{script/deps/deno.land/std@0.208.0 → esm/deps/deno.land/std@0.210.0}/path/posix/to_file_url.d.ts +1 -1
- package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/separator.d.ts +1 -1
- package/esm/deps.d.ts +2 -2
- package/esm/deps.js +2 -2
- package/esm/plugins/for.js +27 -1
- package/esm/plugins/js.js +1 -1
- package/esm/src/environment.d.ts +5 -1
- package/esm/src/environment.js +5 -1
- package/esm/src/tokenizer.js +59 -11
- package/package.json +1 -1
- package/script/deps/deno.land/std@0.210.0/assert/assert.d.ts +12 -0
- package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/assert/assert.js +11 -1
- package/script/deps/deno.land/std@0.210.0/assert/assertion_error.d.ts +14 -0
- package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/assert/assertion_error.js +13 -2
- package/{esm/deps/deno.land/std@0.208.0 → script/deps/deno.land/std@0.210.0}/path/_common/glob_to_reg_exp.d.ts +1 -0
- package/script/deps/deno.land/std@0.210.0/path/common.d.ts +13 -0
- package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/extname.js +1 -1
- package/{esm/deps/deno.land/std@0.208.0 → script/deps/deno.land/std@0.210.0}/path/mod.d.ts +2 -2
- package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/mod.js +3 -1
- package/{esm/deps/deno.land/std@0.208.0 → script/deps/deno.land/std@0.210.0}/path/posix/to_file_url.d.ts +1 -1
- package/script/deps/deno.land/std@0.210.0/path/separator.d.ts +2 -0
- package/script/deps.d.ts +2 -2
- package/script/deps.js +2 -2
- package/script/plugins/for.js +27 -1
- package/script/plugins/js.js +1 -1
- package/script/src/environment.d.ts +5 -1
- package/script/src/environment.js +5 -1
- package/script/src/tokenizer.js +59 -11
- package/esm/deps/deno.land/std@0.208.0/assert/assert.d.ts +0 -2
- package/esm/deps/deno.land/std@0.208.0/assert/assert.js +0 -8
- package/esm/deps/deno.land/std@0.208.0/assert/assertion_error.d.ts +0 -4
- package/esm/deps/deno.land/std@0.208.0/assert/assertion_error.js +0 -7
- package/script/deps/deno.land/std@0.208.0/assert/assert.d.ts +0 -2
- package/script/deps/deno.land/std@0.208.0/assert/assertion_error.d.ts +0 -4
- package/script/deps/deno.land/std@0.208.0/path/posix/common.d.ts +0 -13
- package/script/deps/deno.land/std@0.208.0/path/separator.d.ts +0 -2
- package/script/deps/deno.land/std@0.208.0/path/windows/common.d.ts +0 -13
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/entities.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/entities.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/mod.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/assert_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/assert_path.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/basename.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/common.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/common.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/constants.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/constants.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/dirname.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/format.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/from_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/from_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/glob_to_reg_exp.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize_string.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize_string.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/relative.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/strip_trailing_separators.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/strip_trailing_separators.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/to_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/to_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_interface.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_interface.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_os.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_os.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/basename.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/common.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/dirname.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/extname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/format.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/from_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/from_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/glob_to_regexp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/glob_to_regexp.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_absolute.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_absolute.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_glob.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join_globs.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join_globs.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize_glob.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/parse.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/parse.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/_util.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/_util.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/basename.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0/path → std@0.210.0/path/posix}/common.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/common.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/dirname.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/extname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/extname.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/format.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/from_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/from_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/glob_to_regexp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/glob_to_regexp.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_absolute.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_absolute.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_glob.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join_globs.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join_globs.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/mod.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize_glob.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/parse.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/parse.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/relative.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/resolve.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/resolve.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/separator.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/separator.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/to_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/to_namespaced_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/to_namespaced_path.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/relative.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/resolve.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/resolve.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/separator.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_namespaced_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_namespaced_path.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/_util.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/_util.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/basename.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0/path/posix → std@0.210.0/path/windows}/common.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/common.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/dirname.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/extname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/extname.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/format.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/from_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/from_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/glob_to_regexp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/glob_to_regexp.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_absolute.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_absolute.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_glob.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join_globs.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join_globs.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/mod.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize_glob.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/parse.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/parse.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/relative.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/resolve.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/resolve.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/separator.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/separator.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_file_url.js +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_namespaced_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_namespaced_path.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/entities.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/entities.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/html/mod.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/assert_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/assert_path.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/basename.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/common.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/common.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/constants.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/constants.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/dirname.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/format.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/from_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/from_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/glob_to_reg_exp.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize_string.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/normalize_string.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/relative.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/strip_trailing_separators.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/strip_trailing_separators.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/to_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_common/to_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_interface.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_interface.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_os.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/_os.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/basename.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/common.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/dirname.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/extname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/format.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/from_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/from_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/glob_to_regexp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/glob_to_regexp.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_absolute.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_absolute.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/is_glob.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join_globs.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/join_globs.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/normalize_glob.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/parse.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/parse.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/_util.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/_util.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/basename.js +0 -0
- /package/{esm/deps/deno.land/std@0.208.0/path/windows → script/deps/deno.land/std@0.210.0/path/posix}/common.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/common.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/dirname.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/extname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/extname.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/format.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/from_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/from_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/glob_to_regexp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/glob_to_regexp.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_absolute.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_absolute.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/is_glob.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join_globs.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/join_globs.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/mod.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/normalize_glob.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/parse.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/parse.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/relative.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/resolve.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/resolve.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/separator.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/separator.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/to_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/to_namespaced_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/posix/to_namespaced_path.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/relative.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/resolve.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/resolve.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/separator.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_namespaced_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/to_namespaced_path.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/_util.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/_util.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/basename.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0/path → std@0.210.0/path/windows}/common.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/common.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/dirname.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/extname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/extname.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/format.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/from_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/from_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/glob_to_regexp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/glob_to_regexp.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_absolute.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_absolute.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/is_glob.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join_globs.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/join_globs.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/mod.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/normalize_glob.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/parse.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/parse.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/relative.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/resolve.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/resolve.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/separator.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/separator.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_file_url.js +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_namespaced_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.208.0 → std@0.210.0}/path/windows/to_namespaced_path.js +0 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Make an assertion, error will be thrown if `expr` does not have truthy value.
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* ```ts
|
|
6
|
+
* import { assert } from "https://deno.land/std@$STD_VERSION/assert/assert.ts";
|
|
7
|
+
*
|
|
8
|
+
* assert("hello".includes("ello")); // Doesn't throw
|
|
9
|
+
* assert("hello".includes("world")); // Throws
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
12
|
+
export declare function assert(expr: unknown, msg?: string): asserts expr;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
|
|
2
|
+
import { AssertionError } from "./assertion_error.js";
|
|
3
|
+
/**
|
|
4
|
+
* Make an assertion, error will be thrown if `expr` does not have truthy value.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```ts
|
|
8
|
+
* import { assert } from "https://deno.land/std@$STD_VERSION/assert/assert.ts";
|
|
9
|
+
*
|
|
10
|
+
* assert("hello".includes("ello")); // Doesn't throw
|
|
11
|
+
* assert("hello".includes("world")); // Throws
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
14
|
+
export function assert(expr, msg = "") {
|
|
15
|
+
if (!expr) {
|
|
16
|
+
throw new AssertionError(msg);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Error thrown when an assertion fails.
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* ```ts
|
|
6
|
+
* import { AssertionError } from "https://deno.land/std@$STD_VERSION/assert/assertion_error.ts";
|
|
7
|
+
*
|
|
8
|
+
* throw new AssertionError("Assertion failed");
|
|
9
|
+
* ```
|
|
10
|
+
*/
|
|
11
|
+
export declare class AssertionError extends Error {
|
|
12
|
+
/** Constructs a new instance. */
|
|
13
|
+
constructor(message: string);
|
|
14
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
|
|
2
|
+
/**
|
|
3
|
+
* Error thrown when an assertion fails.
|
|
4
|
+
*
|
|
5
|
+
* @example
|
|
6
|
+
* ```ts
|
|
7
|
+
* import { AssertionError } from "https://deno.land/std@$STD_VERSION/assert/assertion_error.ts";
|
|
8
|
+
*
|
|
9
|
+
* throw new AssertionError("Assertion failed");
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
12
|
+
export class AssertionError extends Error {
|
|
13
|
+
/** Constructs a new instance. */
|
|
14
|
+
constructor(message) {
|
|
15
|
+
super(message);
|
|
16
|
+
this.name = "AssertionError";
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** Determines the common path from a set of paths, using an optional separator,
|
|
2
|
+
* which defaults to the OS default separator.
|
|
3
|
+
*
|
|
4
|
+
* ```ts
|
|
5
|
+
* import { common } from "https://deno.land/std@$STD_VERSION/path/mod.ts";
|
|
6
|
+
* const p = common([
|
|
7
|
+
* "./deno/std/path/mod.ts",
|
|
8
|
+
* "./deno/std/fs/mod.ts",
|
|
9
|
+
* ]);
|
|
10
|
+
* console.log(p); // "./deno/std/"
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
13
|
+
export declare function common(paths: string[], sep?: "/" | "\\"): string;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// This module is browser compatible.
|
|
3
3
|
import { isWindows } from "./_os.js";
|
|
4
4
|
import { extname as posixExtname } from "./posix/extname.js";
|
|
5
|
-
import { extname as windowsExtname } from "./
|
|
5
|
+
import { extname as windowsExtname } from "./windows/extname.js";
|
|
6
6
|
/**
|
|
7
7
|
* Return the extension of the `path` with leading period.
|
|
8
8
|
* @param path with extension
|
|
@@ -4,8 +4,8 @@ import * as _posix from "./posix/mod.js";
|
|
|
4
4
|
export declare const win32: typeof _windows;
|
|
5
5
|
/** @deprecated (will be removed after 1.0.0) Import from {@link https://deno.land/std/posix/mod.ts} instead. */
|
|
6
6
|
export declare const posix: typeof _posix;
|
|
7
|
-
export declare const sep:
|
|
8
|
-
export declare const delimiter:
|
|
7
|
+
export declare const sep: "/" | "\\";
|
|
8
|
+
export declare const delimiter: ":" | ";";
|
|
9
9
|
export * from "./basename.js";
|
|
10
10
|
export * from "./dirname.js";
|
|
11
11
|
export * from "./extname.js";
|
|
@@ -40,7 +40,9 @@ export const win32 = _windows;
|
|
|
40
40
|
/** @deprecated (will be removed after 1.0.0) Import from {@link https://deno.land/std/posix/mod.ts} instead. */
|
|
41
41
|
export const posix = _posix;
|
|
42
42
|
export const sep = isWindows ? _windows.sep : _posix.sep;
|
|
43
|
-
export const delimiter = isWindows
|
|
43
|
+
export const delimiter = isWindows
|
|
44
|
+
? _windows.delimiter
|
|
45
|
+
: _posix.delimiter;
|
|
44
46
|
export * from "./basename.js";
|
|
45
47
|
export * from "./dirname.js";
|
|
46
48
|
export * from "./extname.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const SEP:
|
|
1
|
+
export declare const SEP: "/" | "\\";
|
|
2
2
|
export declare const SEP_PATTERN: RegExp;
|
package/esm/deps.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * as path from "./deps/deno.land/std@0.
|
|
2
|
-
export * as html from "./deps/deno.land/std@0.
|
|
1
|
+
export * as path from "./deps/deno.land/std@0.210.0/path/mod.js";
|
|
2
|
+
export * as html from "./deps/deno.land/std@0.210.0/html/mod.js";
|
package/esm/deps.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * as path from "./deps/deno.land/std@0.
|
|
2
|
-
export * as html from "./deps/deno.land/std@0.
|
|
1
|
+
export * as path from "./deps/deno.land/std@0.210.0/path/mod.js";
|
|
2
|
+
export * as html from "./deps/deno.land/std@0.210.0/html/mod.js";
|
package/esm/plugins/for.js
CHANGED
|
@@ -25,7 +25,9 @@ function forTag(env, code, output, tokens) {
|
|
|
25
25
|
compiled.push("}");
|
|
26
26
|
return compiled.join("\n");
|
|
27
27
|
}
|
|
28
|
-
function toIterator(
|
|
28
|
+
function toIterator(
|
|
29
|
+
// deno-lint-ignore no-explicit-any
|
|
30
|
+
item, withKeys = false) {
|
|
29
31
|
if (item === undefined || item === null) {
|
|
30
32
|
return [];
|
|
31
33
|
}
|
|
@@ -36,6 +38,18 @@ function toIterator(item, withKeys = false) {
|
|
|
36
38
|
return toIterator(item(), withKeys);
|
|
37
39
|
}
|
|
38
40
|
if (typeof item === "object" && item !== null) {
|
|
41
|
+
if (typeof item[Symbol.iterator] === "function") {
|
|
42
|
+
if (withKeys) {
|
|
43
|
+
return iterableToEntries(item);
|
|
44
|
+
}
|
|
45
|
+
return item;
|
|
46
|
+
}
|
|
47
|
+
if (typeof item[Symbol.asyncIterator] === "function") {
|
|
48
|
+
if (withKeys) {
|
|
49
|
+
return asyncIterableToEntries(item);
|
|
50
|
+
}
|
|
51
|
+
return item;
|
|
52
|
+
}
|
|
39
53
|
return withKeys ? Object.entries(item) : Object.values(item);
|
|
40
54
|
}
|
|
41
55
|
if (typeof item === "string") {
|
|
@@ -46,3 +60,15 @@ function toIterator(item, withKeys = false) {
|
|
|
46
60
|
}
|
|
47
61
|
return toIterator([item], withKeys);
|
|
48
62
|
}
|
|
63
|
+
function* iterableToEntries(iterator) {
|
|
64
|
+
let i = 0;
|
|
65
|
+
for (const value of iterator) {
|
|
66
|
+
yield [i++, value];
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
async function* asyncIterableToEntries(iterator) {
|
|
70
|
+
let i = 0;
|
|
71
|
+
for await (const value of iterator) {
|
|
72
|
+
yield [i++, value];
|
|
73
|
+
}
|
|
74
|
+
}
|
package/esm/plugins/js.js
CHANGED
package/esm/src/environment.d.ts
CHANGED
|
@@ -17,7 +17,11 @@ export interface TemplateSync {
|
|
|
17
17
|
file?: string;
|
|
18
18
|
}
|
|
19
19
|
export type Tag = (env: Environment, code: string, output: string, tokens: Token[]) => string | undefined;
|
|
20
|
-
export type
|
|
20
|
+
export type FilterThis = {
|
|
21
|
+
data: Record<string, unknown>;
|
|
22
|
+
env: Environment;
|
|
23
|
+
};
|
|
24
|
+
export type Filter = (this: FilterThis, ...args: any[]) => any;
|
|
21
25
|
export type Plugin = (env: Environment) => void;
|
|
22
26
|
export interface Options {
|
|
23
27
|
loader: Loader;
|
package/esm/src/environment.js
CHANGED
|
@@ -124,7 +124,8 @@ export class Environment {
|
|
|
124
124
|
}
|
|
125
125
|
else {
|
|
126
126
|
// It's a filter (e.g. filters.upper())
|
|
127
|
-
|
|
127
|
+
const { dataVarname } = this.options;
|
|
128
|
+
output = `${(isAsync || checkAsync(this.filters[name])) ? "await " : ""}__env.filters.${name}.call({data:${dataVarname},env:__env}, ${output}${args ? `, ${args}` : ""})`;
|
|
128
129
|
}
|
|
129
130
|
}
|
|
130
131
|
// Escape by default
|
|
@@ -171,3 +172,6 @@ export function errorLine(source, pos) {
|
|
|
171
172
|
}
|
|
172
173
|
return [line, column, source.split("\n")[line - 1]];
|
|
173
174
|
}
|
|
175
|
+
function checkAsync(fn) {
|
|
176
|
+
return fn.constructor?.name === "AsyncFunction";
|
|
177
|
+
}
|
package/esm/src/tokenizer.js
CHANGED
|
@@ -111,7 +111,8 @@ export function parseTag(source) {
|
|
|
111
111
|
statuses.unshift("bracket");
|
|
112
112
|
}
|
|
113
113
|
else if (status !== "comment" && status !== "single-quote" &&
|
|
114
|
-
status !== "double-quote" && status !== "literal"
|
|
114
|
+
status !== "double-quote" && status !== "literal" &&
|
|
115
|
+
status !== "regex" && status !== "line-comment") {
|
|
115
116
|
statuses.unshift("bracket");
|
|
116
117
|
}
|
|
117
118
|
break;
|
|
@@ -136,7 +137,9 @@ export function parseTag(source) {
|
|
|
136
137
|
}
|
|
137
138
|
else if (status !== "comment" &&
|
|
138
139
|
status !== "single-quote" &&
|
|
139
|
-
status !== "literal"
|
|
140
|
+
status !== "literal" &&
|
|
141
|
+
status !== "regex" &&
|
|
142
|
+
status !== "line-comment") {
|
|
140
143
|
statuses.unshift("double-quote");
|
|
141
144
|
}
|
|
142
145
|
break;
|
|
@@ -149,7 +152,9 @@ export function parseTag(source) {
|
|
|
149
152
|
}
|
|
150
153
|
else if (status !== "comment" &&
|
|
151
154
|
status !== "double-quote" &&
|
|
152
|
-
status !== "literal"
|
|
155
|
+
status !== "literal" &&
|
|
156
|
+
status !== "regex" &&
|
|
157
|
+
status !== "line-comment") {
|
|
153
158
|
statuses.unshift("single-quote");
|
|
154
159
|
}
|
|
155
160
|
break;
|
|
@@ -162,23 +167,56 @@ export function parseTag(source) {
|
|
|
162
167
|
}
|
|
163
168
|
else if (status !== "comment" &&
|
|
164
169
|
status !== "double-quote" &&
|
|
165
|
-
status !== "single-quote"
|
|
170
|
+
status !== "single-quote" &&
|
|
171
|
+
status !== "regex" &&
|
|
172
|
+
status !== "line-comment") {
|
|
166
173
|
statuses.unshift("literal");
|
|
167
174
|
}
|
|
168
175
|
break;
|
|
169
176
|
}
|
|
170
|
-
// Detect comments
|
|
177
|
+
// Detect comments and regex
|
|
171
178
|
case "/": {
|
|
172
179
|
const status = statuses[0];
|
|
173
|
-
if (status
|
|
174
|
-
status
|
|
175
|
-
|
|
176
|
-
|
|
180
|
+
if (status === "single-quote" || status === "double-quote" ||
|
|
181
|
+
status === "literal" || status === "line-comment") {
|
|
182
|
+
break;
|
|
183
|
+
}
|
|
184
|
+
// We are in a comment: close or ignore
|
|
185
|
+
if (status === "comment") {
|
|
186
|
+
if (source.charAt(index - 2) === "*") {
|
|
187
|
+
statuses.shift();
|
|
177
188
|
}
|
|
178
|
-
|
|
179
|
-
|
|
189
|
+
break;
|
|
190
|
+
}
|
|
191
|
+
// We are in a regex: close or ignore
|
|
192
|
+
if (status === "regex") {
|
|
193
|
+
if (source.charAt(index - 2) !== "\\") {
|
|
180
194
|
statuses.shift();
|
|
181
195
|
}
|
|
196
|
+
break;
|
|
197
|
+
}
|
|
198
|
+
// Start a new comment
|
|
199
|
+
if (source.charAt(index) === "*") {
|
|
200
|
+
statuses.unshift("comment");
|
|
201
|
+
break;
|
|
202
|
+
}
|
|
203
|
+
// Start a new line comment
|
|
204
|
+
if (source.charAt(index - 2) === "/") {
|
|
205
|
+
statuses.unshift("line-comment");
|
|
206
|
+
break;
|
|
207
|
+
}
|
|
208
|
+
// Start a new regex
|
|
209
|
+
const prev = prevChar(source, index - 1);
|
|
210
|
+
if (prev === "(" || prev === "=" || prev === ":" || prev === ",") {
|
|
211
|
+
statuses.unshift("regex");
|
|
212
|
+
}
|
|
213
|
+
break;
|
|
214
|
+
}
|
|
215
|
+
// Detect end of line comments
|
|
216
|
+
case "\n": {
|
|
217
|
+
const status = statuses[0];
|
|
218
|
+
if (status === "line-comment") {
|
|
219
|
+
statuses.shift();
|
|
182
220
|
}
|
|
183
221
|
break;
|
|
184
222
|
}
|
|
@@ -194,3 +232,13 @@ export function parseTag(source) {
|
|
|
194
232
|
}
|
|
195
233
|
throw new Error("Unclosed tag");
|
|
196
234
|
}
|
|
235
|
+
// Get the previous character in a string ignoring spaces, line breaks and tabs
|
|
236
|
+
function prevChar(source, index) {
|
|
237
|
+
while (index > 0) {
|
|
238
|
+
const char = source.charAt(--index);
|
|
239
|
+
if (char !== " " && char !== "\n" && char !== "\r" && char !== "\t") {
|
|
240
|
+
return char;
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
return "";
|
|
244
|
+
}
|
package/package.json
CHANGED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Make an assertion, error will be thrown if `expr` does not have truthy value.
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* ```ts
|
|
6
|
+
* import { assert } from "https://deno.land/std@$STD_VERSION/assert/assert.ts";
|
|
7
|
+
*
|
|
8
|
+
* assert("hello".includes("ello")); // Doesn't throw
|
|
9
|
+
* assert("hello".includes("world")); // Throws
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
12
|
+
export declare function assert(expr: unknown, msg?: string): asserts expr;
|
|
@@ -3,7 +3,17 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.assert = void 0;
|
|
4
4
|
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
|
|
5
5
|
const assertion_error_js_1 = require("./assertion_error.js");
|
|
6
|
-
/**
|
|
6
|
+
/**
|
|
7
|
+
* Make an assertion, error will be thrown if `expr` does not have truthy value.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* import { assert } from "https://deno.land/std@$STD_VERSION/assert/assert.ts";
|
|
12
|
+
*
|
|
13
|
+
* assert("hello".includes("ello")); // Doesn't throw
|
|
14
|
+
* assert("hello".includes("world")); // Throws
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
7
17
|
function assert(expr, msg = "") {
|
|
8
18
|
if (!expr) {
|
|
9
19
|
throw new assertion_error_js_1.AssertionError(msg);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Error thrown when an assertion fails.
|
|
3
|
+
*
|
|
4
|
+
* @example
|
|
5
|
+
* ```ts
|
|
6
|
+
* import { AssertionError } from "https://deno.land/std@$STD_VERSION/assert/assertion_error.ts";
|
|
7
|
+
*
|
|
8
|
+
* throw new AssertionError("Assertion failed");
|
|
9
|
+
* ```
|
|
10
|
+
*/
|
|
11
|
+
export declare class AssertionError extends Error {
|
|
12
|
+
/** Constructs a new instance. */
|
|
13
|
+
constructor(message: string);
|
|
14
|
+
}
|
|
@@ -1,11 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
// Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
|
|
2
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
4
|
exports.AssertionError = void 0;
|
|
4
|
-
|
|
5
|
+
/**
|
|
6
|
+
* Error thrown when an assertion fails.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```ts
|
|
10
|
+
* import { AssertionError } from "https://deno.land/std@$STD_VERSION/assert/assertion_error.ts";
|
|
11
|
+
*
|
|
12
|
+
* throw new AssertionError("Assertion failed");
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
5
15
|
class AssertionError extends Error {
|
|
6
|
-
|
|
16
|
+
/** Constructs a new instance. */
|
|
7
17
|
constructor(message) {
|
|
8
18
|
super(message);
|
|
19
|
+
this.name = "AssertionError";
|
|
9
20
|
}
|
|
10
21
|
}
|
|
11
22
|
exports.AssertionError = AssertionError;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** Determines the common path from a set of paths, using an optional separator,
|
|
2
|
+
* which defaults to the OS default separator.
|
|
3
|
+
*
|
|
4
|
+
* ```ts
|
|
5
|
+
* import { common } from "https://deno.land/std@$STD_VERSION/path/mod.ts";
|
|
6
|
+
* const p = common([
|
|
7
|
+
* "./deno/std/path/mod.ts",
|
|
8
|
+
* "./deno/std/fs/mod.ts",
|
|
9
|
+
* ]);
|
|
10
|
+
* console.log(p); // "./deno/std/"
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
13
|
+
export declare function common(paths: string[], sep?: "/" | "\\"): string;
|
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
5
5
|
exports.extname = void 0;
|
|
6
6
|
const _os_js_1 = require("./_os.js");
|
|
7
7
|
const extname_js_1 = require("./posix/extname.js");
|
|
8
|
-
const extname_js_2 = require("./
|
|
8
|
+
const extname_js_2 = require("./windows/extname.js");
|
|
9
9
|
/**
|
|
10
10
|
* Return the extension of the `path` with leading period.
|
|
11
11
|
* @param path with extension
|
|
@@ -4,8 +4,8 @@ import * as _posix from "./posix/mod.js";
|
|
|
4
4
|
export declare const win32: typeof _windows;
|
|
5
5
|
/** @deprecated (will be removed after 1.0.0) Import from {@link https://deno.land/std/posix/mod.ts} instead. */
|
|
6
6
|
export declare const posix: typeof _posix;
|
|
7
|
-
export declare const sep:
|
|
8
|
-
export declare const delimiter:
|
|
7
|
+
export declare const sep: "/" | "\\";
|
|
8
|
+
export declare const delimiter: ":" | ";";
|
|
9
9
|
export * from "./basename.js";
|
|
10
10
|
export * from "./dirname.js";
|
|
11
11
|
export * from "./extname.js";
|
|
@@ -69,7 +69,9 @@ exports.win32 = _windows;
|
|
|
69
69
|
/** @deprecated (will be removed after 1.0.0) Import from {@link https://deno.land/std/posix/mod.ts} instead. */
|
|
70
70
|
exports.posix = _posix;
|
|
71
71
|
exports.sep = _os_js_1.isWindows ? _windows.sep : _posix.sep;
|
|
72
|
-
exports.delimiter = _os_js_1.isWindows
|
|
72
|
+
exports.delimiter = _os_js_1.isWindows
|
|
73
|
+
? _windows.delimiter
|
|
74
|
+
: _posix.delimiter;
|
|
73
75
|
__exportStar(require("./basename.js"), exports);
|
|
74
76
|
__exportStar(require("./dirname.js"), exports);
|
|
75
77
|
__exportStar(require("./extname.js"), exports);
|
package/script/deps.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * as path from "./deps/deno.land/std@0.
|
|
2
|
-
export * as html from "./deps/deno.land/std@0.
|
|
1
|
+
export * as path from "./deps/deno.land/std@0.210.0/path/mod.js";
|
|
2
|
+
export * as html from "./deps/deno.land/std@0.210.0/html/mod.js";
|
package/script/deps.js
CHANGED
|
@@ -24,5 +24,5 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.html = exports.path = void 0;
|
|
27
|
-
exports.path = __importStar(require("./deps/deno.land/std@0.
|
|
28
|
-
exports.html = __importStar(require("./deps/deno.land/std@0.
|
|
27
|
+
exports.path = __importStar(require("./deps/deno.land/std@0.210.0/path/mod.js"));
|
|
28
|
+
exports.html = __importStar(require("./deps/deno.land/std@0.210.0/html/mod.js"));
|
package/script/plugins/for.js
CHANGED
|
@@ -28,7 +28,9 @@ function forTag(env, code, output, tokens) {
|
|
|
28
28
|
compiled.push("}");
|
|
29
29
|
return compiled.join("\n");
|
|
30
30
|
}
|
|
31
|
-
function toIterator(
|
|
31
|
+
function toIterator(
|
|
32
|
+
// deno-lint-ignore no-explicit-any
|
|
33
|
+
item, withKeys = false) {
|
|
32
34
|
if (item === undefined || item === null) {
|
|
33
35
|
return [];
|
|
34
36
|
}
|
|
@@ -39,6 +41,18 @@ function toIterator(item, withKeys = false) {
|
|
|
39
41
|
return toIterator(item(), withKeys);
|
|
40
42
|
}
|
|
41
43
|
if (typeof item === "object" && item !== null) {
|
|
44
|
+
if (typeof item[Symbol.iterator] === "function") {
|
|
45
|
+
if (withKeys) {
|
|
46
|
+
return iterableToEntries(item);
|
|
47
|
+
}
|
|
48
|
+
return item;
|
|
49
|
+
}
|
|
50
|
+
if (typeof item[Symbol.asyncIterator] === "function") {
|
|
51
|
+
if (withKeys) {
|
|
52
|
+
return asyncIterableToEntries(item);
|
|
53
|
+
}
|
|
54
|
+
return item;
|
|
55
|
+
}
|
|
42
56
|
return withKeys ? Object.entries(item) : Object.values(item);
|
|
43
57
|
}
|
|
44
58
|
if (typeof item === "string") {
|
|
@@ -49,3 +63,15 @@ function toIterator(item, withKeys = false) {
|
|
|
49
63
|
}
|
|
50
64
|
return toIterator([item], withKeys);
|
|
51
65
|
}
|
|
66
|
+
function* iterableToEntries(iterator) {
|
|
67
|
+
let i = 0;
|
|
68
|
+
for (const value of iterator) {
|
|
69
|
+
yield [i++, value];
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
async function* asyncIterableToEntries(iterator) {
|
|
73
|
+
let i = 0;
|
|
74
|
+
for await (const value of iterator) {
|
|
75
|
+
yield [i++, value];
|
|
76
|
+
}
|
|
77
|
+
}
|
package/script/plugins/js.js
CHANGED
|
@@ -17,7 +17,11 @@ export interface TemplateSync {
|
|
|
17
17
|
file?: string;
|
|
18
18
|
}
|
|
19
19
|
export type Tag = (env: Environment, code: string, output: string, tokens: Token[]) => string | undefined;
|
|
20
|
-
export type
|
|
20
|
+
export type FilterThis = {
|
|
21
|
+
data: Record<string, unknown>;
|
|
22
|
+
env: Environment;
|
|
23
|
+
};
|
|
24
|
+
export type Filter = (this: FilterThis, ...args: any[]) => any;
|
|
21
25
|
export type Plugin = (env: Environment) => void;
|
|
22
26
|
export interface Options {
|
|
23
27
|
loader: Loader;
|
|
@@ -153,7 +153,8 @@ class Environment {
|
|
|
153
153
|
}
|
|
154
154
|
else {
|
|
155
155
|
// It's a filter (e.g. filters.upper())
|
|
156
|
-
|
|
156
|
+
const { dataVarname } = this.options;
|
|
157
|
+
output = `${(isAsync || checkAsync(this.filters[name])) ? "await " : ""}__env.filters.${name}.call({data:${dataVarname},env:__env}, ${output}${args ? `, ${args}` : ""})`;
|
|
157
158
|
}
|
|
158
159
|
}
|
|
159
160
|
// Escape by default
|
|
@@ -202,3 +203,6 @@ function errorLine(source, pos) {
|
|
|
202
203
|
return [line, column, source.split("\n")[line - 1]];
|
|
203
204
|
}
|
|
204
205
|
exports.errorLine = errorLine;
|
|
206
|
+
function checkAsync(fn) {
|
|
207
|
+
return fn.constructor?.name === "AsyncFunction";
|
|
208
|
+
}
|