Skip to content
This repository has been archived by the owner on Apr 1, 2023. It is now read-only.

Commit

Permalink
rename to create-react-library; update demo
Browse files Browse the repository at this point in the history
  • Loading branch information
transitive-bullshit committed Mar 7, 2018
1 parent 74fb484 commit f85175b
Show file tree
Hide file tree
Showing 9 changed files with 26 additions and 10 deletions.
16 changes: 10 additions & 6 deletions README.md
@@ -1,14 +1,16 @@
# react-modern-library-cli
# create-react-library

> CLI for easily publishing modern React modules with Rollup and example usage via create-react-app.
[![NPM](https://img.shields.io/npm/v/react-modern-library-cli.svg)](https://www.npmjs.com/package/react-modern-library-cli) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)
[![NPM](https://img.shields.io/npm/v/create-react-library.svg)](https://www.npmjs.com/package/create-react-library) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

## Intro

**The purpose of this CLI is to make publishing your own React components as simple as possible.**

![](https://raw.githubusercontent.com/transitive-bullshit/react-modern-library-cli/master/media/demo.gif)
<p align="center">
<img width="600" src="https://cdn.rawgit.com/transitive-bullshit/create-react-library/master/media/demo.svg">
</p>

The CLI is based on this [boilerplate](https://github.com/transitive-bullshit/react-modern-library-boilerplate), which you can optionally read in-depth about [here](https://hackernoon.com/publishing-baller-react-modules-2b039d84bce7).

Expand All @@ -31,13 +33,13 @@ The CLI is based on this [boilerplate](https://github.com/transitive-bullshit/re
## Install

```bash
npm install -g react-modern-library-cli
npm install -g create-react-library
```

## Creating a New Module

```bash
react-modern-library-cli
create-react-library
```

Answer some basic prompts about your module, and then the CLI will perform the following steps:
Expand All @@ -48,7 +50,9 @@ Answer some basic prompts about your module, and then the CLI will perform the f

At this point, your new module should resemble this screenshot and is all setup for local development.

![](https://raw.githubusercontent.com/transitive-bullshit/react-modern-library-cli/master/media/demo.png)
<p align="center">
<img width="600" src="https://cdn.rawgit.com/transitive-bullshit/create-react-library/master/media/tree.svg">
</p>

## Development

Expand Down
2 changes: 1 addition & 1 deletion index.js
Expand Up @@ -18,7 +18,7 @@ module.exports = async () => {
if (!module.parent) {
meow(`
Usage
$ react-modern-library-cli
$ create-react-library
`)

module.exports()
Expand Down
5 changes: 5 additions & 0 deletions lib/create-library.js
Expand Up @@ -76,6 +76,11 @@ module.exports.initPackageManager = async (opts) => {
info
} = opts

// TODO: TEMP
return new Promise((resolve) => {
setTimeout(resolve, 2000)
})

const example = path.join(dest, 'example')

const commands = [
Expand Down
5 changes: 5 additions & 0 deletions lib/get-library-defaults.js
Expand Up @@ -11,6 +11,11 @@ module.exports = async () => {
manager: 'npm'
}

// TODO: TEMP
defaults.author = 'transitive-bullshit'
defaults.manager = 'yarn'
return defaults

try {
const gitConfigPath = getGitConfigPath('global')

Expand Down
Binary file removed media/demo.gif
Binary file not shown.
Binary file removed media/demo.png
Binary file not shown.
1 change: 1 addition & 0 deletions media/demo.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions media/tree.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions package.json
@@ -1,12 +1,12 @@
{
"name": "react-modern-library-cli",
"name": "create-react-library",
"version": "1.4.3",
"description": "CLI for easily bootstrapping modern react libraries",
"repository": "transitive-bullshit/react-modern-library-cli",
"repository": "transitive-bullshit/create-react-library",
"main": "index.js",
"license": "MIT",
"bin": {
"react-modern-library-cli": "index.js"
"create-react-library": "index.js"
},
"dependencies": {
"consolidate": "^0.15.0",
Expand Down

0 comments on commit f85175b

Please sign in to comment.