just-boris / create-preact-app Goto Github PK
View Code? Open in Web Editor NEWThis project forked from facebook/create-react-app
Create Preact apps with no build configuration.
License: MIT License
This project forked from facebook/create-react-app
Create Preact apps with no build configuration.
License: MIT License
Yup!
Strangely, I encounter a persistent error on running
create-react-app my-app --scripts-version @just-boris/preact-scripts
I have a feeling it's most likely due to slightly older node/npm or create-react-app, version numbers are printed at the bottom of my terminal contents below.
create-react-app works just fine by the way!
No problem for me just now, I'm just tinkering, but thought I should let you know.
Regards, Jim.
jims-MacBook-Pro-3:temp jim$ mkdir testboris
jims-MacBook-Pro-3:temp jim$ cd testboris/
jims-MacBook-Pro-3:testboris jim$ create-react-app my-app --scripts-version @just-boris/preact-scripts
Creating a new React app in /Users/jim/work/temp/testboris/my-app.
Installing packages. This might take a couple minutes.
Installing react-scripts from npm...
[email protected] install /Users/jim/work/temp/testboris/my-app/node_modules/fsevents
node install
[fsevents] Success: "/Users/jim/work/temp/testboris/my-app/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node" already installed
Pass --update-binary to reinstall or --build-from-source to recompile
[email protected] postinstall /Users/jim/work/temp/testboris/my-app/node_modules/uglifyjs-webpack-plugin
node lib/post_install.js
[email protected] /Users/jim/work/temp/testboris/my-app
└─┬ @just-boris/[email protected]
├─┬ [email protected]
(ETC ETC.... looks nice all the packages get installed
module.js:457
throw err;
^
Error: Cannot find module '/Users/jim/work/temp/testboris/my-app/node_modules/package.json'
at Function.Module._resolveFilename (module.js:455:15)
at Function.Module._load (module.js:403:25)
at Module.require (module.js:483:17)
at require (internal/module.js:20:19)
at checkNodeVersion (/Users/jim/.nvm/versions/node/v6.7.0/lib/node_modules/create-react-app/index.js:170:21)
at ChildProcess. (/Users/jim/.nvm/versions/node/v6.7.0/lib/node_modules/create-react-app/index.js:127:5)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:877:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
jims-MacBook-Pro-3:testboris jim$ ls
my-app
jims-MacBook-Pro-3:testboris jim$ ls my-app/node_modules/package.json
ls: my-app/node_modules/package.json: No such file or directory
jims-MacBook-Pro-3:testboris jim$ npm -v
3.10.3
jims-MacBook-Pro-3:testboris jim$ node -v
v6.7.0
jims-MacBook-Pro-3:testboris jim$ npm ls react-scripts
/Users/jim
└── (empty)
npm ERR! code 1
jims-MacBook-Pro-3:testboris jim$ create-react-app --help
Usage: create-react-app [--verbose]
jims-MacBook-Pro-3:testboris jim$ create-react-app --version
create-react-app version: 0.5.0
jims-MacBook-Pro-3:testboris jim$
No
I use CRA, and having built a react + webpack app from scratch earlier, the CRA adds quite some extra bytes along in the final bundles.
Want to understand numbers of the CPA, how much difference in bytes and performance have you benchmarked compared to CRA.
Also if the difference is significant, probably you can add it in the README for others to see another reason to use Preact over React. (I don't bias in either, but I prefer to see a minimal bundle size at the end when using boilerplates)
Backstroke is dead, at least. create-preact-app
is not updating either. There are a lot of new versions of react-scripts
. I have a problem with the 1.1.4 of react-scripts
, looking for an update up to 2.0+
Is it enough to just update react-scripts
inside your lib?
Hey. I've had trouble using an object as a class in jsx with this package. According to the preact docs and the repl on preactjs.com what's supposed to happen is that the object keys with truthy values get used as classes. Instead, I just end up with a class of [object Object]. Suggestions?
I got an error: 'h' must be in scope when using JSX
I'm manually tweaking react dependency from a react template and got this. What should I do?
Create-react-app allows users to npm run eject
from the default config, copying build config to a local dir and running webpack from that - more info.
Any chance of that coming to preact?
The react script doesnt seem to support preact compat, which is important for packages like mobx to work. Any plans to support this?
hello!
thanks for the project. i noticed that the last release was in ~January, but the upstream has been blazing ahead. is the backstroke integration down?
thanks!
Do i need to install preact
and preact-compat
after installation via this script?
Any reason why preact
and preact-compat
doesn't get installed automatically @just-boris
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.