Skip to content

Commit

Permalink
Update npm definition and package file for publishing (ampproject#34333)
Browse files Browse the repository at this point in the history
  • Loading branch information
krdwan authored and rochapablo committed Aug 30, 2021
1 parent 45285c4 commit adaa134
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 1 deletion.
10 changes: 9 additions & 1 deletion build-system/compile/bundles.config.extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -635,7 +635,15 @@
"cssBinaries": ["amp-truncate-text", "amp-truncate-text-shadow"]
}
},
{"name": "amp-twitter", "version": ["0.1", "1.0"], "latestVersion": "0.1"},
{"name": "amp-twitter", "version": "0.1", "latestVersion": "0.1"},
{
"name": "amp-twitter",
"version": "1.0",
"latestVersion": "0.1",
"options": {
"npm": true
}
},
{
"name": "amp-user-notification",
"version": "0.1",
Expand Down
31 changes: 31 additions & 0 deletions extensions/amp-twitter/1.0/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"name": "@ampproject/amp-twitter",
"version": "VERSION",
"description": "AMP Twitter Component",
"author": "The AMP HTML Authors",
"license": "Apache-2.0",
"main": "dist/component.js",
"module": "dist/component.mjs",
"exports": {
".": "./preact",
"./preact": {
"import": "dist/component-preact.mjs",
"require": "dist/component-preact.js"
},
"./react": {
"import": "dist/component-react.mjs",
"require": "dist/component-react.js"
}
},
"files": ["dist/*"],
"repository": {
"type": "git",
"url": "https://github.com/ampproject/amphtml.git",
"directory": "extensions/amp-twitter/1.0"
},
"homepage": "https://github.com/ampproject/amphtml/tree/main/extensions/amp-twitter/1.0",
"peerDependencies": {
"preact": "^10.2.1",
"react": "^17.0.0"
}
}

0 comments on commit adaa134

Please sign in to comment.