4.0.0 • Published 2 years ago

@contrast/distringuish-prebuilt v4.0.0

Weekly downloads
3,921
License
SEE LICENSE IN LI...
Repository
-
Last release
2 years ago

@contrast/distringuish-prebuilt

Node native module for tracking string literals with string externalization.

See this article for technical details.

Usage

const distringuish = require('@contrast/distringuish-prebuilt');

const externalString = distringuish.externalize(someString);
const props = distringuish.getProperties(externalString); // => {}
props.key = 'value';
// the object returned maintains properties pinned to the string
distringuish.getProperties(externalString); // => { key: "value" }

API

See index.d.ts.

externalize(str: string): string | number;
getProperties(str: string): Record<string, any> | null;
isExternal(str: string): boolean;
internalize(str: string): string;

Building locally

npm run build will build the project for your current OS and architecture. npm run build:dev passes the --debug flag which can be useful during development.

npm run download will pull the most recent build artifacts from GitHub.

Publishing

Simply run npm version and git push && git push --tags. CI will take care of releasing on tagged commits.

Style Guide

See .clang-format.

  • 4 spaces for indentation
  • open curly brace goes on the same line as the statement
4.0.0

2 years ago

3.1.0-beta.1

2 years ago

3.1.0-beta.2

2 years ago

3.0.0-beta.8

2 years ago

3.1.0-beta.3

2 years ago

3.1.0-beta.0

2 years ago

3.2.0

2 years ago

3.1.0

2 years ago

3.0.1

2 years ago

3.0.0

2 years ago

2.2.3

2 years ago

2.2.2

2 years ago

2.2.4

2 years ago

2.2.1

3 years ago

2.2.0

3 years ago

2.1.1

3 years ago

2.1.0

3 years ago

2.0.3

3 years ago

2.0.2

3 years ago

2.0.1

3 years ago

2.0.0

4 years ago

1.9.0

4 years ago

1.9.0-beta.1

4 years ago

1.9.0-beta.0

4 years ago

1.8.6

4 years ago

1.8.5

4 years ago

1.8.4

4 years ago

1.8.2

4 years ago

1.8.1

4 years ago

1.8.0

5 years ago

1.7.1

5 years ago

1.7.0

5 years ago