This repository has been archived by the owner on Feb 2, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
47 changed files
with
617 additions
and
451 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# editorconfig.org | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
node_modules/ | ||
lib/plugins/nuxtentBodyComponent.template.js | ||
dist/ | ||
nuxt/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"root": true, | ||
"parser": "babel-eslint", | ||
"parserOptions": { | ||
"ecmaVersion": 8, | ||
"sourceType": "module" | ||
}, | ||
"env": { | ||
"node": true, | ||
"es6": true | ||
}, | ||
"plugins": [ | ||
"babel", | ||
"ava" | ||
], | ||
"extends": [ | ||
"eslint-config-standard", | ||
"eslint-config-i-am-meticulous", | ||
"plugin:ava/recommended", | ||
"eslint-config-prettier" | ||
], | ||
"rules": { | ||
"curly": [ | ||
"error", | ||
"all" | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
rules: { | ||
"import/no-unresolved": 0 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
module.exports = { | ||
content: { | ||
page: '/guide/_slug', | ||
permalink: ":slug", | ||
permalink: ':slug', | ||
isPost: false | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,28 @@ | ||
const Prism = require('prismjs') | ||
|
||
module.exports = { | ||
content: { // basic content configuration | ||
content: { | ||
// basic content configuration | ||
permalink: ':slug', | ||
isPost: false | ||
}, | ||
|
||
parser: { // custom parser options | ||
parser: { | ||
// custom parser options | ||
md: { | ||
highlight: (code, lang) => { | ||
return Prism.highlight(code, Prism.languages[lang] || Prism.languages.markup) | ||
return Prism.highlight( | ||
code, | ||
Prism.languages[lang] || Prism.languages.markup | ||
) | ||
} | ||
} | ||
}, | ||
|
||
api: { // custom url for development and production builds | ||
baseURL: process.env.NODE_ENV ? | ||
'https://production-url.now.sh' : | ||
'http://localhost:3000' | ||
api: { | ||
// custom url for development and production builds | ||
baseURL: process.env.NODE_ENV | ||
? 'https://production-url.now.sh' | ||
: 'http://localhost:3000' | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"name": "nuxtent-example", | ||
"version": "1.0.0", | ||
"description": "nuxtent custom-build example", | ||
"author": "Alid Castano <[email protected]>", | ||
"dependencies": { | ||
"@nuxtjs/axios": "^2.2.1", | ||
"nuxt": "latest", | ||
"nuxtent": "latest", | ||
"prismjs": "^1.8.1" | ||
}, | ||
"scripts": { | ||
"dev": "nuxt", | ||
"build": "nuxt build", | ||
"start": "nuxt start", | ||
"generate": "nuxtent generate" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
module.exports = { | ||
loading: { color: 'cyan' }, | ||
modules: [ | ||
'nuxtent' | ||
] | ||
modules: ['nuxtent'] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
module.exports = { | ||
modules: [ | ||
'nuxtent' | ||
] | ||
modules: ['nuxtent'] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
module.exports = { | ||
content: { | ||
page: '/_slug', | ||
permalink: "/:slug", | ||
permalink: '/:slug', | ||
isPost: false, | ||
generate: ['get'] | ||
generate: ['get', 'getAll'] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,19 @@ | ||
<template> | ||
<div> | ||
<h1> Markdown Component </h1> | ||
<h1> {{ post.title }} </h1> | ||
<div> | ||
<h1>{{ post.title }}</h1> | ||
<nuxtent-body v-if="isObject(post.body)" :body="post.body" /> | ||
<div v-else v-html="post.body" /> | ||
<!-- <ContentComp /> --> | ||
<nuxtent-body :body="post.body" /> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
async asyncData ({ app, route, payload }) { | ||
async asyncData ({ app, route }) { | ||
return { | ||
post: payload || await app.$content('/').get(route.params.slug) | ||
post: await app.$content('/').get(route.params.slug) | ||
} | ||
}, | ||
methods: { | ||
isObject (body) { | ||
return typeof body === 'object' | ||
} | ||
}, | ||
components: { | ||
// ContentComp: () => import('~/content/HelloWorld.comp.md') | ||
} | ||
} | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
module.exports = { | ||
modules: [ | ||
'nuxtent' | ||
] | ||
modules: ['nuxtent'] | ||
} |
Oops, something went wrong.