Page Starter is a page template backed by prismic.io CMS.
Create your own account and repo on prismic.io.
Create the Custom Type of your page in prismic.io Writing-room
-
Navigate to
Setting
/Custom types
-
Create a new
type-id
and and aType label
that correspond to a page. for examplepage
,Page
. -
Start with using this sample page Custom Type.
- This type contains 4 different slices alternated-highlights, featured-items, slides and a separator as well as a uid (a unique identifier) and a title for your page.
Create an instance of you custom types
- Navigate to
Your documents
/Write something
- Choose the custom type you have created
- Start by adding your page content
Slices
on the left sideAdd a Content Slice...
(Slides
,Featured Items
,Alternated Highlights
,separator
) - Finally add your page url
unique-identifier-for-page-url
in Metadata tab (uid) and you Page meta title for example :page-starter-sample-page
,Page Starter Sample Page
- Save and publish
- Download the latest release
- Unzip locally or on your server
Edit the prismic-configuration.js
file to get the application connected to the right repository:
exports.Configuration = {
apiEndpoint: 'https://lesbonneschoses.prismic.io/api',
// -- Access token if the Master is not open
// accessToken: 'xxxxxx',
// OAuth
// clientId: 'xxxxxx',
// clientSecret: 'xxxxxx',
...
- Install npm & node
To run it on your local machine, 2 possibilities:
In command line:
- using nodemon (node wrapper)
npm install -g nodemon
nodemon app
- using node
npm install
node app
You are all set, just navigate to /page-starter-sample-page
to open your Page...
This Website Starter uses Jade - Template Engine.
To adapt the design of your web site; you can modify the corresponding slices in jade located in: /views
.
An easy way to deploy your NodeJS application is to use Heroku. Just follow these few simple steps once you have successfully signed up and installed the Heroku toolbelt:
Create a Procfile
file at your application root, to declare the server command:
web: node app.js
Create a new Heroku application
$ heroku create
Push your code to heroku:
$ git push heroku master
Ensure you have at least one node running:
$ heroku ps:scale web=1
You can now browse your application online:
$ heroku open
You can find out how to get started with prismic.io on our prismic.io developer's portal.
You'll find more information about how to use the development kit included in this starter project, by reading its README file.
Contribution is open to all developer levels, read our "Contribute to the official kits" documentation to learn more.
This software is licensed under the Apache 2 license, quoted below.
Copyright 2013 Zengularity (http://www.zengularity.com).
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this project except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.