From 98ea2d7578bb274f94f80969f6d34bcd3235077a Mon Sep 17 00:00:00 2001 From: Brent Jackson Date: Sun, 17 Feb 2019 15:43:39 -0500 Subject: [PATCH] Adjust build setup --- babel.config.js | 7 ------- docs/index.mdx | 2 +- lib/config.js | 26 +------------------------- lib/html-plugin.js | 1 + package.json | 3 +-- 5 files changed, 4 insertions(+), 35 deletions(-) delete mode 100644 babel.config.js diff --git a/babel.config.js b/babel.config.js deleted file mode 100644 index 6be1ad8..0000000 --- a/babel.config.js +++ /dev/null @@ -1,7 +0,0 @@ -module.exports = { - presets: ['@babel/env', '@babel/react'], - plugins: [ - '@babel/plugin-proposal-class-properties', - '@babel/plugin-proposal-export-namespace-from', - ], -} diff --git a/docs/index.mdx b/docs/index.mdx index 253602d..c1d0d42 100644 --- a/docs/index.mdx +++ b/docs/index.mdx @@ -1,4 +1,4 @@ -import { Head, Image, Notes, Appear } from '../dist' +import { Head, Image, Notes, Appear } from '..' MDX Deck Demo diff --git a/lib/config.js b/lib/config.js index 777fa01..a8c354a 100644 --- a/lib/config.js +++ b/lib/config.js @@ -52,30 +52,6 @@ const rules = [ }, ] -/* -const template = ({ - head = 'mdx-deck', - css = '', - body = '', - js, - publicPath, -}) => ` - - - - - - -${head}${css} - - -
${body}
-${HTMLPlugin.generateJSReferences(js, publicPath)} - - -` -*/ - const baseConfig = { stats: 'errors-only', mode: 'development', @@ -111,7 +87,7 @@ const createConfig = (opts = {}) => { path.join(opts.dirname, 'node_modules') ) - config.entry = [path.join(__dirname, '../dist/entry.js')] + config.entry = [path.join(__dirname, '../src/entry.js')] const defs = Object.assign({}, opts.globals, { OPTIONS: JSON.stringify(opts), diff --git a/lib/html-plugin.js b/lib/html-plugin.js index 3a1b09e..9abc823 100644 --- a/lib/html-plugin.js +++ b/lib/html-plugin.js @@ -72,6 +72,7 @@ const defaultTemplate = ({ + ${head}${css}${links} diff --git a/package.json b/package.json index 6fd3ee2..e5a081e 100644 --- a/package.json +++ b/package.json @@ -2,12 +2,11 @@ "name": "mdx-deck", "version": "1.8.2", "description": "MDX-based presentation decks", - "main": "dist/index.js", + "main": "src/index.js", "bin": { "mdx-deck": "./cli.js" }, "scripts": { - "prepare": "babel src -d dist", "watch": "babel src -d dist --watch", "start": "./cli.js docs/index.mdx -p 8080", "build": "./cli.js build docs/index.mdx -d site",