Skip to content

Commit 35b2c06

Browse files
authored
Improve dev build performance, remove purs-loader (#8)
1 parent cc11c94 commit 35b2c06

File tree

6 files changed

+555
-231
lines changed

6 files changed

+555
-231
lines changed

docs/App.jsx

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import Media from "react-media";
44
import Loadable from "react-loadable";
55
import changeCase from "change-case";
66

7-
import { colors, colorNames } from "../src/Lumi/Components/Color";
8-
import { column, column_ } from "../src/Lumi/Components/Column";
9-
import { row, row_ } from "../src/Lumi/Components/Row";
7+
import { colors, colorNames } from "purs/Lumi.Components.Color";
8+
import { column, column_ } from "purs/Lumi.Components.Column";
9+
import { row, row_ } from "purs/Lumi.Components.Row";
1010
import {
1111
text,
1212
body_,
@@ -17,13 +17,13 @@ import {
1717
subtext_,
1818
h1_,
1919
h3_
20-
} from "../src/Lumi/Components/Text";
21-
import { icon, iconRearrange } from "../src/Lumi/Components/Icon";
22-
import { loader } from "../src/Lumi/Components/Loader";
23-
import { exampleStyleToggle } from "./Example";
24-
import { dragDropContext } from "./App.purs_bundle_hacks";
25-
import { cssStringHSLA } from "./ColorHelper";
26-
import { attachGlobalComponentStyles } from "../src/Lumi/Components/Styles";
20+
} from "purs/Lumi.Components.Text";
21+
import { icon, iconRearrange } from "purs/Lumi.Components.Icon";
22+
import { loader } from "purs/Lumi.Components.Loader";
23+
import { exampleStyleToggle } from "purs/Lumi.Components.Example";
24+
import { dragDropContext } from "purs/AppSetup";
25+
import { cssStringHSLA } from "purs/Color";
26+
import { attachGlobalComponentStyles } from "purs/Lumi.Components.Styles";
2727

2828
attachGlobalComponentStyles();
2929

@@ -34,7 +34,9 @@ const fromComponentPath = title => ({
3434
loader: () =>
3535
// Note: The string bits inside `require(...)` need to stay static strings, or Webpack
3636
// won't be able to infer which files need to be included in the bundle.
37-
import(`./Examples/${title}.example`).then(module_ => () => module_.docs),
37+
import(`purs/Lumi.Components.Examples.${title}`).then(module_ => () =>
38+
module_.docs
39+
),
3840
loading: () => null // these load quickly enough that a noisy loader makes it look slower
3941
}),
4042
title,

docs/App.purs_bundle_hacks.purs renamed to docs/AppSetup.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
module Lumi.Components where
1+
module AppSetup where
22

33
import React.Basic (JSX)
44
import React.Basic.ReactDND (createDragDropContext)

docs/ColorHelper.purs

Lines changed: 0 additions & 6 deletions
This file was deleted.

0 commit comments

Comments
 (0)