Skip to content

Commit 376ae3f

Browse files
committed
create index.d.ts
1 parent b6f80ef commit 376ae3f

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

index.d.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
export default class GEmojiElement extends HTMLElement {
2+
image?: HTMLImageElement
3+
}

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"description": "Backports native emoji characters to browsers that don't support them by replacing the characters with fallback images.",
55
"main": "dist/index.umd.js",
66
"module": "dist/index.esm.js",
7+
"types": "dist/index.d.ts",
78
"license": "MIT",
89
"repository": "github/g-emoji-element",
910
"files": [
@@ -13,7 +14,7 @@
1314
"clean": "rm -rf dist",
1415
"lint": "github-lint",
1516
"prebuild": "npm run clean && npm run lint && mkdir dist",
16-
"build": "rollup -c && cp index.js.flow dist/index.esm.js.flow && cp index.js.flow dist/index.umd.js.flow",
17+
"build": "rollup -c && cp index.js.flow dist/index.esm.js.flow && cp index.js.flow dist/index.umd.js.flow && cp index.d.ts dist/index.d.ts",
1718
"pretest": "npm run build",
1819
"test": "karma start test/karma.config.js",
1920
"prepublishOnly": "npm run build"

0 commit comments

Comments
 (0)