Skip to content

Commit

Permalink
Bundle Plugins and Carousel from index
Browse files Browse the repository at this point in the history
This is also the entry point for tree shaking. Utils and types are omitted in favor of importing them directly via `caroucssel/utils/..`, `caroucssel/plugins/..`, `caroucssel/types`.
  • Loading branch information
Norman Rusch committed Sep 21, 2021
1 parent 887532a commit bda5791
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 13 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "caroucssel",
"version": "0.12.0-0",
"description": "A lightweight dependency-free css carousel.",
"module": "dist/caroucssel.js",
"module": "dist/index.js",
"main": "dist/caroucssel.cjs.js",
"unpkg": "dist/caroucssel.min.js",
"types": "dist/caroucssel.d.ts",
Expand Down
12 changes: 5 additions & 7 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
import { Buttons } from './plugins/buttons';
import { Mask } from './plugins/mask';
import { Pagination } from './plugins/pagination';


export { Carousel } from './caroucssel';
export const plugins = { Buttons, Mask, Pagination };
export { Buttons } from './plugins/buttons';
export { Mask } from './plugins/mask';
export { Mouse } from './plugins/mouse';
export { Pagination } from './plugins/pagination';
export * from './caroucssel';
6 changes: 1 addition & 5 deletions tsconfig.build.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
{
"extends": "./tsconfig.json",
"include": [
"./src/caroucssel.ts",
"./src/plugins/buttons/index.ts",
"./src/plugins/mask/index.ts",
"./src/plugins/mouse/index.ts",
"./src/plugins/pagination/index.ts"
"./src/index.ts"
],
"compilerOptions": {
"declarationMap": false,
Expand Down

0 comments on commit bda5791

Please sign in to comment.