astrotim / contentful-static-react Goto Github PK
View Code? Open in Web Editor NEWA starter kit for building a static website with React as the templating library and Contentful as the CMS.
A starter kit for building a static website with React as the templating library and Contentful as the CMS.
I've followed the steps from your tutorial and am able to run yarn build
successfully on my local. However, when I try to deploy via Travis I get the following when it hits the react-snap
step:
0.01s
1.38sadding /home/travis/.cache/yarn to cache
$ node --version
v8.11.2
$ npm --version
5.6.0
$ nvm --version
0.33.11
$ yarn --version
1.3.2
install
29.00s$ yarn install
yarn install v1.3.2
[1/4] Resolving packages...
[2/4] Fetching packages...
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
Done in 28.56s.
37.23s$ yarn build
yarn run v1.3.2
$ react-scripts build
Creating an optimized production build...
Compiled successfully.
File sizes after gzip:
98.89 KB build/static/js/main.6d89d9d6.js
425 B build/static/css/main.6ad777ba.css
The project was built assuming it is hosted at the server root.
You can control this with the homepage field in your package.json.
For example, add this to build it for GitHub Pages:
"homepage" : "http://myname.github.io/myapp",
The build folder is ready to be deployed.
You may serve it with a static server:
yarn global add serve
serve -s build
Find out more about deployment here:
http://bit.ly/2vY88Kr
$ react-snap
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
The command "yarn build" exited with 1.
cache.2
store build cache
0.01s
11.94schanges detected, packing new archive
.
uploading archive
Done. Your build exited with 1.
I've tried playing around with node and yarn versions, matching them to my local, but it always seizes up in the same place. I'm thinking that it's due to a missing permission or configuration somewhere related to S3 or Travis. Any thoughts?
Hi
When I deploy locally the static build works great but when deploy in CircleCl it keeps timing out on react snap:
error at / { Error: Protocol error (Page.enable): Target closed.
at Promise (/home/circleci/project/node_modules/puppeteer/lib/Connection.js:186:56)
at new Promise ()
at CDPSession.send (/home/circleci/project/node_modules/puppeteer/lib/Connection.js:185:12)
Any ideas?
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.