Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
50 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
packages/email-all-chars-within-ascii/coverage/coverage-summary.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
{"total":{"lines":{"total":25,"covered":25,"skipped":0,"pct":100},"statements":{"total":27,"covered":27,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"branches":{"total":34,"covered":34,"skipped":0,"pct":100}}} | ||
{"total":{"lines":{"total":26,"covered":26,"skipped":0,"pct":100},"statements":{"total":28,"covered":28,"skipped":0,"pct":100},"functions":{"total":1,"covered":1,"skipped":0,"pct":100},"branches":{"total":34,"covered":34,"skipped":0,"pct":100}}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
packages/email-all-chars-within-ascii/dist/email-all-chars-within-ascii.umd.js
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
{"_quickTake.js":{"title":"Quick Take","content":"import { strict as assert } from \"assert\";\nimport { within } from \"email-all-chars-within-ascii\";\n\n// enforces all characters to be within ASCII:\nassert.deepEqual(within(`<div>Motörhead</div>`), [\n {\n type: \"character\",\n line: 1,\n column: 9,\n positionIdx: 8,\n value: \"ö\",\n codePoint: 246,\n },\n]);\n\n// enforces line lengths (500 is best for email):\nassert.deepEqual(within(`abcde`, { lineLength: 3 }), [\n {\n type: \"line length\",\n line: 1,\n column: 5,\n positionIdx: 5,\n value: 5,\n },\n]);"}} | ||
{"_quickTake.js":{"title":"Quick Take","content":"import { strict as assert } from \"assert\";\nimport { within } from \"email-all-chars-within-ascii\";\n\n// enforces all characters to be within ASCII:\nassert.deepEqual(within(`<div>Motörhead</div>`), [\n {\n type: \"character\",\n line: 1,\n column: 9,\n positionIdx: 8,\n value: \"ö\",\n codePoint: 246,\n UTF32Hex: \"00f6\",\n },\n]);\n\n// enforces line lengths (500 is best for email):\nassert.deepEqual(within(`abcde`, { lineLength: 3 }), [\n {\n type: \"line length\",\n line: 1,\n column: 5,\n positionIdx: 5,\n value: 5,\n },\n]);"}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,17 @@ | ||
import { version } from "../package.json"; | ||
declare const version: string; | ||
interface Res { | ||
type: "character" | "line length"; | ||
line: number; | ||
column: number; | ||
positionIdx: number; | ||
value: number | string; | ||
codePoint?: undefined | number; | ||
UTF32Hex?: undefined | string; | ||
} | ||
interface Opts { | ||
lineLength: number; | ||
} | ||
declare const defaults: Opts; | ||
declare function within(str: string, originalOpts?: Opts): Res[]; | ||
export { within, defaults, version }; | ||
declare function within(str: string, originalOpts?: Partial<Opts>): Res[]; | ||
|
||
export { defaults, version, within }; |