Skip to content

Commit 90fe93b

Browse files
authored
Merge pull request #6 from mbrookson/bugfix/transitions-example
Fix build for example site
2 parents 4010f29 + b14f348 commit 90fe93b

File tree

6 files changed

+100
-61
lines changed

6 files changed

+100
-61
lines changed

example/package-lock.json

Lines changed: 82 additions & 47 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

example/package.json

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,24 @@
99
"build:css": "postcss tailwind.css -o styles.css"
1010
},
1111
"dependencies": {
12+
"@fullhuman/postcss-purgecss": "^2.1.2",
1213
"components": "^0.1.0",
14+
"autoprefixer": "^9.7.6",
15+
"cssnano": "^4.1.10",
16+
"parcel-bundler": "^1.12.4",
17+
"postcss-cli": "^7.1.0",
18+
"tailwindcss": "^1.3.5",
19+
"typescript": "^3.4.5",
1320
"react-app-polyfill": "^1.0.0",
14-
"react-icons": "^3.10.0"
21+
"react-icons-kit": "^1.3.1"
1522
},
1623
"alias": {
1724
"react": "../node_modules/react",
1825
"react-dom": "../node_modules/react-dom/profiling",
1926
"scheduler/tracing": "../node_modules/scheduler/tracing-profiling"
2027
},
2128
"devDependencies": {
22-
"@fullhuman/postcss-purgecss": "^2.1.2",
2329
"@types/react": "^16.9.11",
24-
"@types/react-dom": "^16.8.4",
25-
"autoprefixer": "^9.7.6",
26-
"cssnano": "^4.1.10",
27-
"parcel": "^1.12.3",
28-
"postcss-cli": "^7.1.0",
29-
"tailwindcss": "^1.3.5",
30-
"typescript": "^3.4.5"
30+
"@types/react-dom": "^16.8.4"
3131
}
3232
}

example/postcss.config.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@ const tailwindcss = require('tailwindcss');
22
const autoprefixer = require('autoprefixer');
33
const cssnano = require('cssnano');
44
const purgecss = require('@fullhuman/postcss-purgecss')({
5-
content: ['./*.html', './*.tsx', './components/*.tsx'],
5+
content: ['./*.html', './*.tsx', './src/*.tsx'],
66
defaultExtractor: content => content.match(/[\w-/:]+(?<!:)/g) || [],
77
});
88

9+
console.log(`NODE_ENV: ${process.env.NODE_ENV}`);
10+
911
module.exports = {
1012
plugins: [
1113
tailwindcss(),

example/src/Header.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as React from 'react';
2-
import { FaGithub } from 'react-icons/fa';
2+
import { Icon } from 'react-icons-kit';
3+
import { github } from 'react-icons-kit/fa/github';
34
// @ts-ignore
45
import images from '../*.png';
56

@@ -11,7 +12,7 @@ export const Header = () => {
1112
<div className="lg:pr-16">
1213
<h1 className="mb-4 text-5xl font-bold">React Simple Hook Modal</h1>
1314
<div className="flex flex-row items-center justify-center lg:justify-end pb-8">
14-
<FaGithub className="inline" />
15+
<Icon icon={github} className="inline" />
1516
<a
1617
className="ml-2 hover:text-blue-300 transition transition-colors duration-200"
1718
href="https://github.com/mbrookson/react-simple-hook-modal"

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"license": "MIT",
44
"name": "react-simple-hook-modal",
55
"description": "A simple React modal with hook based API",
6-
"homepage": "https://github.com/mbrookson/react-simple-hook-modal",
6+
"homepage": "https://react-simple-hook-modal.now.sh",
77
"repository": {
88
"type": "git",
99
"url": "https://github.com/mbrookson/react-simple-hook-modal.git"
@@ -21,6 +21,7 @@
2121
"scripts": {
2222
"start": "tsdx watch",
2323
"build": "tsdx build",
24+
"build:all": "tsdx build && cd example && npm install && npm run build",
2425
"test": "tsdx test --passWithNoTests",
2526
"lint": "tsdx lint",
2627
"install-peers": "install-peers -f"

0 commit comments

Comments
 (0)