emoji-space-shim 0.0.0 β 0.1.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/package.json +38 -43
- package/readme.md +24 -0
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "emoji-space-shim",
|
|
3
3
|
"author": "ehmpathy",
|
|
4
4
|
"description": "shim console.log to fix emoji space render issues across terminals",
|
|
5
|
-
"version": "0.
|
|
5
|
+
"version": "0.1.2",
|
|
6
6
|
"repository": "ehmpathy/emoji-space-shim",
|
|
7
7
|
"homepage": "https://github.com/ehmpathy/emoji-space-shim",
|
|
8
8
|
"keywords": [
|
|
@@ -24,16 +24,43 @@
|
|
|
24
24
|
"files": [
|
|
25
25
|
"/dist"
|
|
26
26
|
],
|
|
27
|
+
"scripts": {
|
|
28
|
+
"build:ts": "tsc -p ./tsconfig.build.json",
|
|
29
|
+
"commit:with-cli": "npx cz",
|
|
30
|
+
"fix:format:biome": "biome check --write",
|
|
31
|
+
"fix:format": "npm run fix:format:biome",
|
|
32
|
+
"fix:lint": "biome check --write",
|
|
33
|
+
"fix": "npm run fix:format && npm run fix:lint",
|
|
34
|
+
"build:clean:bun": "rm -f ./bin/*.bc",
|
|
35
|
+
"build:clean:tsc": "(chmod -R u+w dist 2>/dev/null || true) && rm -rf dist/",
|
|
36
|
+
"build:clean": "npm run build:clean:tsc && npm run build:clean:bun",
|
|
37
|
+
"build:compile:tsc": "tsc -p ./tsconfig.build.json && tsc-alias -p ./tsconfig.build.json",
|
|
38
|
+
"build:compile": "npm run build:compile:tsc && npm run build:compile:bun --if-present",
|
|
39
|
+
"build": "npm run build:clean && npm run build:compile && npm run build:complete --if-present",
|
|
40
|
+
"test:commits": "LAST_TAG=$(git describe --tags --abbrev=0 @^ 2> /dev/null || git rev-list --max-parents=0 HEAD) && npx commitlint --from $LAST_TAG --to HEAD --verbose",
|
|
41
|
+
"test:types": "tsc -p ./tsconfig.json --noEmit",
|
|
42
|
+
"test:format:biome": "biome format",
|
|
43
|
+
"test:format": "npm run test:format:biome",
|
|
44
|
+
"test:lint:deps": "npx depcheck -c ./.depcheckrc.yml",
|
|
45
|
+
"test:lint:biome": "biome check --diagnostic-level=error",
|
|
46
|
+
"test:lint:biome:all": "biome check",
|
|
47
|
+
"test:lint": "npm run test:lint:biome && npm run test:lint:deps",
|
|
48
|
+
"test:unit": "jest -c ./jest.unit.config.ts --forceExit --verbose --passWithNoTests $([ -z $THOROUGH ] && echo '--changedSince=main') $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
49
|
+
"test:integration": "jest -c ./jest.integration.config.ts --forceExit --verbose --passWithNoTests $([ -z $THOROUGH ] && echo '--changedSince=main') $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
50
|
+
"test:acceptance:locally": "npm run build && LOCALLY=true jest -c ./jest.acceptance.config.ts --forceExit --verbose --runInBand --passWithNoTests $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
51
|
+
"test": "npm run test:commits && npm run test:types && npm run test:format && npm run test:lint && npm run test:unit && npm run test:integration && npm run test:acceptance:locally",
|
|
52
|
+
"test:acceptance": "npm run build && jest -c ./jest.acceptance.config.ts --forceExit --verbose --runInBand --passWithNoTests $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
53
|
+
"prepush": "npm run test && npm run build",
|
|
54
|
+
"prepublish": "npm run build",
|
|
55
|
+
"preversion": "npm run prepush",
|
|
56
|
+
"postversion": "git push origin HEAD --tags --no-verify",
|
|
57
|
+
"prepare:husky": "husky install && chmod ug+x .husky/*",
|
|
58
|
+
"prepare:rhachet": "rhachet init --mode upsert && rhachet roles link --repo ehmpathy --role mechanic && rhachet roles link --repo bhuild --role behaver && rhachet roles link --repo bhrain --role reviewer && rhachet roles init --role mechanic && rhachet roles init --role behaver",
|
|
59
|
+
"prepare": "if [ -e .git ] && [ -z $CI ]; then npm run prepare:husky && npm run prepare:rhachet; fi"
|
|
60
|
+
},
|
|
27
61
|
"dependencies": {
|
|
28
|
-
"as-procedure": "1.1.11",
|
|
29
62
|
"domain-objects": "0.31.9",
|
|
30
|
-
"
|
|
31
|
-
"hash-fns": "1.1.0",
|
|
32
|
-
"helpful-errors": "1.5.3",
|
|
33
|
-
"iso-time": "1.10.1",
|
|
34
|
-
"rhachet-artifact": "1.0.3",
|
|
35
|
-
"serde-fns": "1.3.0",
|
|
36
|
-
"type-fns": "1.21.0"
|
|
63
|
+
"helpful-errors": "1.5.3"
|
|
37
64
|
},
|
|
38
65
|
"devDependencies": {
|
|
39
66
|
"@biomejs/biome": "2.3.8",
|
|
@@ -69,37 +96,5 @@
|
|
|
69
96
|
"path": "./node_modules/cz-conventional-changelog"
|
|
70
97
|
}
|
|
71
98
|
},
|
|
72
|
-
"
|
|
73
|
-
|
|
74
|
-
"commit:with-cli": "npx cz",
|
|
75
|
-
"fix:format:biome": "biome check --write",
|
|
76
|
-
"fix:format": "npm run fix:format:biome",
|
|
77
|
-
"fix:lint": "biome check --write",
|
|
78
|
-
"fix": "npm run fix:format && npm run fix:lint",
|
|
79
|
-
"build:clean:bun": "rm -f ./bin/*.bc",
|
|
80
|
-
"build:clean:tsc": "(chmod -R u+w dist 2>/dev/null || true) && rm -rf dist/",
|
|
81
|
-
"build:clean": "npm run build:clean:tsc && npm run build:clean:bun",
|
|
82
|
-
"build:compile:tsc": "tsc -p ./tsconfig.build.json && tsc-alias -p ./tsconfig.build.json",
|
|
83
|
-
"build:compile": "npm run build:compile:tsc && npm run build:compile:bun --if-present",
|
|
84
|
-
"build": "npm run build:clean && npm run build:compile && npm run build:complete --if-present",
|
|
85
|
-
"test:commits": "LAST_TAG=$(git describe --tags --abbrev=0 @^ 2> /dev/null || git rev-list --max-parents=0 HEAD) && npx commitlint --from $LAST_TAG --to HEAD --verbose",
|
|
86
|
-
"test:types": "tsc -p ./tsconfig.json --noEmit",
|
|
87
|
-
"test:format:biome": "biome format",
|
|
88
|
-
"test:format": "npm run test:format:biome",
|
|
89
|
-
"test:lint:deps": "npx depcheck -c ./.depcheckrc.yml",
|
|
90
|
-
"test:lint:biome": "biome check --diagnostic-level=error",
|
|
91
|
-
"test:lint:biome:all": "biome check",
|
|
92
|
-
"test:lint": "npm run test:lint:biome && npm run test:lint:deps",
|
|
93
|
-
"test:unit": "jest -c ./jest.unit.config.ts --forceExit --verbose --passWithNoTests $([ -z $THOROUGH ] && echo '--changedSince=main') $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
94
|
-
"test:integration": "jest -c ./jest.integration.config.ts --forceExit --verbose --passWithNoTests $([ -z $THOROUGH ] && echo '--changedSince=main') $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
95
|
-
"test:acceptance:locally": "npm run build && LOCALLY=true jest -c ./jest.acceptance.config.ts --forceExit --verbose --runInBand --passWithNoTests $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
96
|
-
"test": "npm run test:commits && npm run test:types && npm run test:format && npm run test:lint && npm run test:unit && npm run test:integration && npm run test:acceptance:locally",
|
|
97
|
-
"test:acceptance": "npm run build && jest -c ./jest.acceptance.config.ts --forceExit --verbose --runInBand --passWithNoTests $([ -n $RESNAP ] && echo '--updateSnapshot')",
|
|
98
|
-
"prepush": "npm run test && npm run build",
|
|
99
|
-
"prepublish": "npm run build",
|
|
100
|
-
"preversion": "npm run prepush",
|
|
101
|
-
"postversion": "git push origin HEAD --tags --no-verify",
|
|
102
|
-
"prepare:husky": "husky install && chmod ug+x .husky/*",
|
|
103
|
-
"prepare:rhachet": "rhachet init --mode upsert && rhachet roles link --repo ehmpathy --role mechanic && rhachet roles link --repo bhuild --role behaver && rhachet roles link --repo bhrain --role reviewer && rhachet roles init --role mechanic && rhachet roles init --role behaver"
|
|
104
|
-
}
|
|
105
|
-
}
|
|
99
|
+
"packageManager": "pnpm@10.24.0"
|
|
100
|
+
}
|
package/readme.md
CHANGED
|
@@ -6,6 +6,30 @@ shim console.log to fix emoji space render issues across terminals.
|
|
|
6
6
|
|
|
7
7
|
some emojis render incorrectly across different terminals due to character width inconsistencies. for example, the beaver emoji (`π¦«`) may appear to "eat" the space after it in VS Code's terminal, while it renders correctly in other terminals.
|
|
8
8
|
|
|
9
|
+
### before (without shim)
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
// vscode terminal - space after emoji is "eaten"
|
|
13
|
+
console.log('𦫠beaver')
|
|
14
|
+
β π¦«beaver β space disappeared!
|
|
15
|
+
|
|
16
|
+
// other terminals - renders correctly
|
|
17
|
+
console.log('𦫠beaver')
|
|
18
|
+
β 𦫠beaver β space preserved
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
### after (with shim)
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
// vscode terminal - shim adds extra space to compensate
|
|
25
|
+
console.log('𦫠beaver')
|
|
26
|
+
β 𦫠beaver β looks correct!
|
|
27
|
+
|
|
28
|
+
// other terminals - no adjustment needed
|
|
29
|
+
console.log('𦫠beaver')
|
|
30
|
+
β 𦫠beaver β still correct
|
|
31
|
+
```
|
|
32
|
+
|
|
9
33
|
## solution
|
|
10
34
|
|
|
11
35
|
this package provides a shim that automatically adjusts space after emojis based on the detected terminal. this ensures consistent visual output.
|