A large collection of useful Typescript libraries for Deno. Each utility is provided in its own file at the root.
This monorepo also includes a few related npm modules to make working with Deno better.
Check the license information for the functionality you want. If permitted, import the functions you need.
import * as yamlTag from 'https://x.kite.run/lib/yaml-tag.ts'
This library used to be available at deno.land/x/lib
.
After the Deno team decided to break import URLs, the canonical import domain came into being.
Creates an iterator that is abortable. Based on the npm package by the same name
Parse a string of text as ArchieML.
Utilities for parsing CLI arguments.
Debugging utility for Deno. Ported from the npm package by the same name.
Dedent is a tagged template literal function. It is used by yaml-tag.ts and has tests to ensure consistency with a whitespace-sensitive content.
Parse File-level JSDoc from a folder of TS/JS files for document generation
TypeScript types for Drone CI configuration.
Simple and modern async event emitter Ported from the node [email protected]
Kite™️ Support for OpenFaaS Functions.
Simplified async error handling in TypeScript.
Take a JavaScript object and compute a sha256 hash of it for comparison.
Parses Cache-Control and other headers. Helps building correct HTTP caches and proxies. Ported from the npm package by the same name. Code optained via the BSD-2 license. See attribution below.
A library and DSL to generate karabiner.json config. Can result in a 30x line reduction.
- Call rule()
- Call out()
Kite™️ is a Simplified Config Generation Library Ground Rules:
- No async code. Ever.
- No console.log
- post-processors cannot generate new objects
- Everything is a function. Export it as default and optionally call make() if import.meta.main
- Contract: All module functions should be a function that accepts or ignores one object argument.
- make() should always be in scope for all config gen modules.
Kubernetes Config Generation Library Refer to kite.ts for more info.
kx is a simplified Kubernetes Config SDK for Kite.
Manipulate strings like a wizard NOTE: This is the ES bundle with the sourcemap-codec import corrected. Source is available at https://cdn.jsdelivr.net/npm/[email protected]/dist/magic-string.es.js
A port of npm/apache-md5 for use with htpasswd. Portions of this work were obtained via the MIT License. Copyright (c) Gevorg Harutyunyan.
Provides generic object merging functions. Useful for config generation. Portions of this work were obtained via the Apache 2.0 License. That original work is Copyright 2020, jk authors.
Chainable Promise Proxy utility. Proxymise allows for method and property chaining without need for intermediate then() or await for cleaner and simpler code. @see https://github.com/kozhevnikov/proxymise
A shim for test functions when running Deno code. Consider using @brandonkal/deno-quokka and babel-plugin-deno npm packages for a more robust debugging experience.
CLI to reload Deno files as required. Pass number of commits to have the files reloaded.
Recursively resolve any promises in an object to form a resulting JSON structure.
Recursively resolve any promises in an object to form a resulting JSON structure.
Retry an async function for exponential backoff. With a retryFetch implementation.
A Deno port of the great RunTypes library. Use TypeScript in the runtime. Port introduces loose conversion. This means a check() call may modify if a property required. Primitives should be assigned to themselves. "false" | "true" > boolean "null" > null "42" > 42 See https://github.com/brandonkal/runtypes
Utilities to sandbox subprocess commands
Encode/decode sourcemap mappings
Utilities for testing. Replicates expect from Jest.
Converts JSON structure to ArchieML text string.
Undo String.raw
.
Convert raw escape sequences to their respective characters.
A collection of useful small functions in one location.
Parses YAML or JSON input and prints out YAML documents with a stable object sort. Ideal for converting JSON to YAML. Useful as a lightweight CLI or as a formatting function.
Write YAML within TypeScript programs for cleaner and more concise code. This module provides the following exports:
- y (yaml text tagged template function)
- printYaml (JS Object Array to YAML multi-document text)
This npm module provides basic Quokka.js support for executing Deno files. This helps speed up development of Deno libraries such as yaml-tag.ts
.
This npm module rewrites imports to use the cache directory.
It can be used in combination with @brandonkal/deno-quokka
for an interactive REPL for some Deno-flavored TypeScript code.
Debug a Deno program via Node.
Contributions or requests for focused utilities are encouraged.
© 2020 Brandon Kalinowski (@brandonkal). All rights reserved.
Not all files are released under a permissive open source license (though many are).
In particular, the modules in the kite
directory do not carry an open-source license.
See individual file headers for license information. Files without headers are © Brandon Kalinowski (@brandonkal). All rights reserved.
If a file contains no specified license, no license has been provided.
It's simple really. Each module in this repository could have been released in its own repository. In the npm world, that would mean a seperate package. Each of those would contain their own license. With Deno, files are modules. The file is the distributed content. There is no "minification" step. Therefore, it is smarter to specify license information inside the files. It would be silly to provide a blanket license over the entire repository contents as that would require that a single license would apply to all files.
This approach also makes automation of license compliance simpler. The rules above are simple. You can use doc-gen.ts
or another JSDoc parser to scan the file's structured header block for all your imports.