-
Notifications
You must be signed in to change notification settings - Fork 26
/
compositor.json
96 lines (96 loc) · 4.32 KB
/
compositor.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
{
"name": "hackoregon/civic",
"version": "0.1.4",
"libraries": {
"xv": "^1.1.25"
},
"title": "Hack Oregon - Civic ",
"branch": "",
"style": {
"name": "Future",
"componentSet": {
"nav": "nav/BasicNav",
"header": "header/BannerHeader",
"article": "article/BasicArticle",
"footer": "footer/BasicFooter"
},
"fontFamily": "\"Avenir Next\", Helvetica, sans-serif",
"heading": {
"fontWeight": 500,
"textTransform": "uppercase",
"letterSpacing": "0.2em"
},
"alternativeText": {
"textTransform": "uppercase",
"fontWeight": 400,
"letterSpacing": "0.2em",
"opacity": 0.75
},
"colors": {
"text": "#333",
"background": "#fff",
"primary": "#666",
"secondary": "#888",
"highlight": "#1f80ff",
"muted": "#f6f6f6",
"border": "#eee"
},
"layout": {
"centered": true,
"maxWidth": 1024,
"bannerHeight": "80vh"
}
},
"content": [
{
"component": "nav",
"links": [
{
"href": "https://github.com/hackoregon/civic",
"text": "GitHub"
},
{
"href": "https://npmjs.com/package/civic",
"text": "npm"
}
]
},
{
"component": "header",
"heading": "civic",
"subhead": "This is a lerna (lernajs.io) monorepo for Civic",
"children": [
{
"component": "ui/TweetButton",
"text": "civic: This is a lerna (lernajs.io) monorepo for Civic",
"url": null
},
{
"component": "ui/GithubButton",
"user": "hackoregon",
"repo": "civic"
}
]
},
{
"component": "article",
"metadata": {
"source": "github.readme"
},
"html": "\n<p>Welcome to Civic's platform monorepo.</p>\n<p>This is a lerna based monorepo. Check out lernajs.io for any in-depth docs if you need to debug. Otherwise follow along:</p>\n<h2>Setup</h2>\n<pre>nvm use\nnpm install <span class=\"hljs-comment\">#don't use npm 5</span></pre><p>This will bootstrap the project by installing all package dependencies and linking cross-dependencies.</p>\n<h2>Building Packages</h2>\n<pre>npm run build</pre><p>This will run <code>learna run build</code>, which in turn runs <code>npm run build</code> in each package. <strong>There is no need to run this\ncommand if you will only be working in one package</strong>.</p>\n<p>Certain packages require an env set using the <code>BABEL_ENV</code> or <code>NODE_ENV</code> environment variables to run.</p>\n<h3>Specify the environment for you session</h3>\n<pre><span class=\"hljs-built_in\">export</span> BABEL_ENV=development\nnpm run build</pre><h3>Specify the environment for the command</h3>\n<pre>BABEL_ENV=development npm run build</pre><h3>Specify the environment for all sessions</h3>\n<p>Add <code>export BABEL_ENV=development</code> to your <code>.bashrc</code> file (or respective rc file for your shell).</p>\n<h2>Working on a Package</h2>\n<p>At this point, Lerna has prepared all packages in the monorepo. To now work on one, <code>cd</code> into the package directory,\nand work on it as if it were a standalone project.</p>\n<pre><span class=\"hljs-built_in\">cd</span> packages/housing\nnpm run start</pre><h2>Using the Global Storybook</h2>\n<p>We are committed to a shared component library. This is achieved using the <code>component-library</code> package and React Storybook.\nRun Storybook with the following command:</p>\n<pre>npm run storybook</pre><h3>Testing across all packages</h3>\n<p>To run all tests for all packages, use the following command:</p>\n<pre>npm <span class=\"hljs-built_in\">test</span></pre><p>Tests for individual packages can be run from within the package directory. Running all tests is useful for continuous integration\nenvironments as well as verifying changes to common dependencies does not break packages. For example, run this after making changes\nto a component in the component library to ensure that others packages are compatible with the changes made.</p>\n"
},
{
"component": "footer",
"links": [
{
"href": "https://github.com/hackoregon/civic",
"text": "GitHub"
},
{
"href": "https://github.com/hackoregon",
"text": "hackoregon"
}
]
}
]
}