mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Updated docs links to best equivalents (#10386)
* Updated docs links to best equivalents - Our documentation has been overhauled, this updates the all the old links sprinkled through Ghost * Update integrity hash
This commit is contained in:
parent
2aec5db811
commit
909f9012ed
21 changed files with 42 additions and 43 deletions
|
@ -28,7 +28,7 @@ function sendMail(object) {
|
|||
type: 'warn',
|
||||
message: [
|
||||
common.i18n.t('warnings.index.unableToSendEmail'),
|
||||
common.i18n.t('common.seeLinkForInstructions', {link: 'https://docs.ghost.org/docs/mail-config'})
|
||||
common.i18n.t('common.seeLinkForInstructions', {link: 'https://docs.ghost.org/mail/'})
|
||||
].join(' ')
|
||||
}]
|
||||
},
|
||||
|
|
|
@ -18,7 +18,7 @@ _private.sendMail = (object) => {
|
|||
type: 'warn',
|
||||
message: [
|
||||
common.i18n.t('warnings.index.unableToSendEmail'),
|
||||
common.i18n.t('common.seeLinkForInstructions', {link: 'https://docs.ghost.org/docs/mail-config'})
|
||||
common.i18n.t('common.seeLinkForInstructions', {link: 'https://docs.ghost.org/mail/'})
|
||||
].join(' ')
|
||||
}]
|
||||
},
|
||||
|
|
|
@ -11,7 +11,7 @@ module.exports = function registerHelpers(ghost) {
|
|||
flagKey: 'subscribers',
|
||||
flagName: 'Subscribers',
|
||||
helperName: 'subscribe_form',
|
||||
helpUrl: 'https://help.ghost.org/hc/en-us/articles/224089787-Subscribers-Beta'
|
||||
helpUrl: 'https://docs.ghost.org/faq/enable-subscribers-feature/'
|
||||
}, () => {
|
||||
return require('./subscribe_form').apply(self, args);
|
||||
});
|
||||
|
|
|
@ -59,14 +59,14 @@ DataImporter = {
|
|||
if (!importData.meta) {
|
||||
throw new common.errors.IncorrectUsageError({
|
||||
message: 'Wrong importer structure. `meta` is missing.',
|
||||
help: 'https://docs.ghost.org/docs/the-importer'
|
||||
help: 'https://docs.ghost.org/api/migration/#json-file-structure'
|
||||
});
|
||||
}
|
||||
|
||||
if (!importData.meta.version) {
|
||||
throw new common.errors.IncorrectUsageError({
|
||||
message: 'Wrong importer structure. `meta.version` is missing.',
|
||||
help: 'https://docs.ghost.org/docs/the-importer'
|
||||
help: 'https://docs.ghost.org/api/migration/#json-file-structure'
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -76,7 +76,7 @@ DataImporter = {
|
|||
if (!semver.valid(importData.meta.version)) {
|
||||
return Promise.reject(new common.errors.InternalServerError({
|
||||
message: 'Detected unsupported file structure.',
|
||||
context: 'Please install Ghost 1.0, import the file and then update your blog to Ghost 2.0.\nVisit https://docs.ghost.org/v1/docs/install or ask for help in our https://forum.ghost.org.'
|
||||
context: 'Please install Ghost 1.0, import the file and then update your blog to Ghost 2.0.\nVisit https://docs.ghost.org/faq/upgrade-to-ghost-1-0 or ask for help in our https://forum.ghost.org.'
|
||||
}));
|
||||
}
|
||||
|
||||
|
|
|
@ -86,7 +86,7 @@
|
|||
"defaultValue": "{}"
|
||||
},
|
||||
"navigation": {
|
||||
"defaultValue": "[{\"label\":\"Home\", \"url\":\"/\"},{\"label\":\"Tag\", \"url\":\"/tag/getting-started/\"}, {\"label\":\"Author\", \"url\":\"/author/ghost/\"},{\"label\":\"Help\", \"url\":\"https://help.ghost.org\"}]"
|
||||
"defaultValue": "[{\"label\":\"Home\", \"url\":\"/\"},{\"label\":\"Tag\", \"url\":\"/tag/getting-started/\"}, {\"label\":\"Author\", \"url\":\"/author/ghost/\"},{\"label\":\"Help\", \"url\":\"https://docs.ghost.org\"}]"
|
||||
},
|
||||
"slack": {
|
||||
"defaultValue": "[{\"url\":\"\", \"username\":\"Ghost\"}]"
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -364,7 +364,7 @@ validateRedirects = function validateRedirects(redirects) {
|
|||
if (!_.isArray(redirects)) {
|
||||
throw new common.errors.ValidationError({
|
||||
message: common.i18n.t('errors.utils.redirectsWrongFormat'),
|
||||
help: 'https://docs.ghost.org/docs/redirects'
|
||||
help: 'https://docs.ghost.org/concepts/redirects/'
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -373,7 +373,7 @@ validateRedirects = function validateRedirects(redirects) {
|
|||
throw new common.errors.ValidationError({
|
||||
message: common.i18n.t('errors.utils.redirectsWrongFormat'),
|
||||
context: JSON.stringify(redirect),
|
||||
help: 'https://docs.ghost.org/docs/redirects'
|
||||
help: 'https://docs.ghost.org/concepts/redirects/'
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
|
@ -192,7 +192,7 @@ module.exports = function getLabsWrapper() {
|
|||
flagKey: 'publicAPI',
|
||||
flagName: 'Public API',
|
||||
helperName: 'get',
|
||||
helpUrl: 'https://help.ghost.org/hc/en-us/articles/115000301672-Public-API-Beta',
|
||||
helpUrl: 'https://docs.ghost.org/faq/api-versioning/',
|
||||
async: true
|
||||
}, function executeHelper() {
|
||||
return get.apply(self, args);
|
||||
|
|
|
@ -14,7 +14,7 @@ pagination = function (options) {
|
|||
throw new errors.IncorrectUsageError({
|
||||
level: 'normal',
|
||||
message: i18n.t('warnings.helpers.pagination.invalidData'),
|
||||
help: 'https://themes.ghost.org/docs/pagination'
|
||||
help: 'https://docs.ghost.org/api/handlebars-themes/helpers/pagination/'
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ function parsePackageJson(path) {
|
|||
if (!hasRequiredKeys) {
|
||||
err = new Error(common.i18n.t('errors.utils.parsepackagejson.nameOrVersionMissing'));
|
||||
err.context = path;
|
||||
err.help = common.i18n.t('errors.utils.parsepackagejson.willBeRequired', {url: 'https://themes.ghost.org/'});
|
||||
err.help = common.i18n.t('errors.utils.parsepackagejson.willBeRequired', {url: 'https://docs.ghost.org/api/handlebars-themes/'});
|
||||
|
||||
return Promise.reject(err);
|
||||
}
|
||||
|
@ -39,7 +39,7 @@ function parsePackageJson(path) {
|
|||
} catch (parseError) {
|
||||
err = new Error(common.i18n.t('errors.utils.parsepackagejson.themeFileIsMalformed'));
|
||||
err.context = path;
|
||||
err.help = common.i18n.t('errors.utils.parsepackagejson.willBeRequired', {url: 'https://themes.ghost.org/'});
|
||||
err.help = common.i18n.t('errors.utils.parsepackagejson.willBeRequired', {url: 'https://docs.ghost.org/api/handlebars-themes/'});
|
||||
|
||||
return Promise.reject(err);
|
||||
}
|
||||
|
|
|
@ -48,7 +48,7 @@ GhostMailer.prototype.getDomain = function () {
|
|||
GhostMailer.prototype.send = function (message) {
|
||||
var self = this,
|
||||
to,
|
||||
help = common.i18n.t('errors.api.authentication.checkEmailConfigInstructions', {url: 'https://docs.ghost.org/docs/mail-config'}),
|
||||
help = common.i18n.t('errors.api.authentication.checkEmailConfigInstructions', {url: 'https://docs.ghost.org/mail/'}),
|
||||
errorMessage = common.i18n.t('errors.mail.failedSendingEmail.error');
|
||||
|
||||
// important to clone message as we modify it
|
||||
|
|
|
@ -573,7 +573,7 @@
|
|||
"isDeprecated": "Warning: pageUrl is deprecated, please use page_url instead\nThe helper pageUrl has been replaced with page_url in Ghost 0.4.2, and will be removed entirely in Ghost 0.6\nIn your theme's pagination.hbs file, pageUrl should be renamed to page_url"
|
||||
},
|
||||
"pagination": {
|
||||
"invalidData": "The \\{\\{pagination\\}\\} helper was used outside of a paginated context. See https://themes.ghost.org/docs/pagination.",
|
||||
"invalidData": "The \\{\\{pagination\\}\\} helper was used outside of a paginated context. See https://docs.ghost.org/api/handlebars-themes/helpers/pagination/.",
|
||||
"valuesMustBeDefined": "All values must be defined for page, pages, limit and total",
|
||||
"nextPrevValuesMustBeNumeric": "Invalid value, Next/Prev must be a number",
|
||||
"valuesMustBeNumeric": "Invalid value, check page, pages, limit and total are numbers"
|
||||
|
|
|
@ -76,7 +76,7 @@ _private.registerRoutes = () => {
|
|||
common.logging.error(new common.errors.IncorrectUsageError({
|
||||
message: common.i18n.t('errors.middleware.redirects.register'),
|
||||
context: err.message,
|
||||
help: 'https://docs.ghost.org/docs/redirects'
|
||||
help: 'https://docs.ghost.org/concepts/redirects/'
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
@ -86,7 +86,7 @@ _private.registerRoutes = () => {
|
|||
|
||||
/**
|
||||
* - you can extend Ghost with a custom redirects file
|
||||
* - see https://github.com/TryGhost/Ghost/issues/7707 and https://docs.ghost.org/docs/redirects
|
||||
* - see https://github.com/TryGhost/Ghost/issues/7707 and https://docs.ghost.org/concepts/redirects/
|
||||
* - file loads synchronously, because we need to register the routes before anything else
|
||||
*/
|
||||
exports.use = function use(siteApp) {
|
||||
|
|
|
@ -20,7 +20,7 @@ var should = require('should'),
|
|||
describe('DB version integrity', function () {
|
||||
// Only these variables should need updating
|
||||
const currentSchemaHash = 'b865478398cd2b0a1e5eaffebccdb88c';
|
||||
const currentFixturesHash = '8b36d1e72c29b7f9073612142b5a8783';
|
||||
const currentFixturesHash = 'cc19eac0f38ed778d25c82753f687495';
|
||||
|
||||
// If this test is failing, then it is likely a change has been made that requires a DB version bump,
|
||||
// and the values above will need updating as confirmation
|
||||
|
@ -42,4 +42,3 @@ describe('DB version integrity', function () {
|
|||
fixturesHash.should.eql(currentFixturesHash);
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
@ -49,7 +49,7 @@ describe('{{#get}} helper', function () {
|
|||
'string',
|
||||
'<script>console.error("The {{get}} helper is not available. ' +
|
||||
'The Public API flag must be enabled in labs if you wish to use the {{get}} helper. ' +
|
||||
'See https://help.ghost.org/hc/en-us/articles/115000301672-Public-API-Beta");</script>'
|
||||
'See https://docs.ghost.org/faq/api-versioning/");</script>'
|
||||
);
|
||||
|
||||
done();
|
||||
|
|
|
@ -28,7 +28,7 @@ describe('{{pagination}} helper', function () {
|
|||
return function () {
|
||||
helpers.pagination.call(data);
|
||||
};
|
||||
}, expectedMessage = 'The {{pagination}} helper was used outside of a paginated context. See https://themes.ghost.org/docs/pagination.';
|
||||
}, expectedMessage = 'The {{pagination}} helper was used outside of a paginated context. See https://docs.ghost.org/api/handlebars-themes/helpers/pagination/.';
|
||||
|
||||
runHelper('not an object').should.throwError(expectedMessage);
|
||||
runHelper(function () {
|
||||
|
|
|
@ -45,7 +45,7 @@ describe('lib/fs/package-json: parse', function () {
|
|||
.catch(function (err) {
|
||||
err.message.should.equal('"name" or "version" is missing from theme package.json file.');
|
||||
err.context.should.equal(tmpFile.name);
|
||||
err.help.should.equal('This will be required in future. Please see https://themes.ghost.org/');
|
||||
err.help.should.equal('This will be required in future. Please see https://docs.ghost.org/api/handlebars-themes/');
|
||||
|
||||
done();
|
||||
})
|
||||
|
@ -70,7 +70,7 @@ describe('lib/fs/package-json: parse', function () {
|
|||
.catch(function (err) {
|
||||
err.message.should.equal('"name" or "version" is missing from theme package.json file.');
|
||||
err.context.should.equal(tmpFile.name);
|
||||
err.help.should.equal('This will be required in future. Please see https://themes.ghost.org/');
|
||||
err.help.should.equal('This will be required in future. Please see https://docs.ghost.org/api/handlebars-themes/');
|
||||
|
||||
done();
|
||||
})
|
||||
|
@ -93,7 +93,7 @@ describe('lib/fs/package-json: parse', function () {
|
|||
.catch(function (err) {
|
||||
err.message.should.equal('Theme package.json file is malformed');
|
||||
err.context.should.equal(tmpFile.name);
|
||||
err.help.should.equal('This will be required in future. Please see https://themes.ghost.org/');
|
||||
err.help.should.equal('This will be required in future. Please see https://docs.ghost.org/api/handlebars-themes/');
|
||||
|
||||
done();
|
||||
})
|
||||
|
|
|
@ -68,7 +68,7 @@ describe('Themes', function () {
|
|||
fatal: true,
|
||||
level: 'error',
|
||||
rule: 'Replace the <code>{{#if author.cover}}</code> helper with <code>{{#if author.cover_image}}</code>',
|
||||
details: 'The <code>cover</code> attribute was replaced with <code>cover_image</code>.<br>Instead of <code>{{#if author.cover}}</code> you need to use <code>{{#if author.cover_image}}</code>.<br>See the object attributes of <code>author</code> <a href="https://themes.ghost.org/docs/author-context#section-author-object-attributes" target=_blank>here</a>.',
|
||||
details: 'The <code>cover</code> attribute was replaced with <code>cover_image</code>.<br>Instead of <code>{{#if author.cover}}</code> you need to use <code>{{#if author.cover_image}}</code>.<br>See the object attributes of <code>author</code> <a href="https://docs.ghost.org/api/handlebars-themes/context/author/#author-object-attributes" target=_blank>here</a>.',
|
||||
failures: [ {} ],
|
||||
code: 'GS001-DEPR-CON-AC'
|
||||
}
|
||||
|
@ -98,7 +98,7 @@ describe('Themes', function () {
|
|||
fatal: true,
|
||||
level: 'error',
|
||||
rule: 'Replace the <code>{{#if author.cover}}</code> helper with <code>{{#if author.cover_image}}</code>',
|
||||
details: 'The <code>cover</code> attribute was replaced with <code>cover_image</code>.<br>Instead of <code>{{#if author.cover}}</code> you need to use <code>{{#if author.cover_image}}</code>.<br>See the object attributes of <code>author</code> <a href="https://themes.ghost.org/docs/author-context#section-author-object-attributes" target=_blank>here</a>.',
|
||||
details: 'The <code>cover</code> attribute was replaced with <code>cover_image</code>.<br>Instead of <code>{{#if author.cover}}</code> you need to use <code>{{#if author.cover_image}}</code>.<br>See the object attributes of <code>author</code> <a href="https://docs.ghost.org/api/handlebars-themes/context/author/#author-object-attributes" target=_blank>here</a>.',
|
||||
failures: [ {} ],
|
||||
code: 'GS001-DEPR-CON-AC'
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -1090,10 +1090,10 @@
|
|||
"uuid": "8c414ae2-dce6-4b0f-8ee6-5c403fa2ae86",
|
||||
"title": "Setting up your own Ghost theme",
|
||||
"slug": "themes",
|
||||
"mobiledoc": "{\"version\":\"0.3.1\",\"markups\":[],\"atoms\":[],\"cards\":[[\"card-markdown\",{\"cardName\":\"card-markdown\",\"markdown\":\"Creating a totally custom design for your publication\\n\\nGhost comes with a beautiful default theme called Casper, which is designed to be a clean, readable publication layout and can be easily adapted for most purposes. However, Ghost can also be completely themed to suit your needs. Rather than just giving you a few basic settings which act as a poor proxy for code, we just let you write code.\\n\\nThere are a huge range of both free and premium pre-built themes which you can get from the [Ghost Theme Marketplace](http://marketplace.ghost.org), or you can simply create your own from scratch.\\n\\n[](http://marketplace.ghost.org)\\n\\n> Anyone can write a completely custom Ghost theme, with just some solid knowledge of HTML and CSS\\n\\nGhost themes are written with a templating language called handlebars, which has a bunch of dynamic helpers to insert your data into template files. Like `{{author.name}}`, for example, outputs the name of the current author.\\n\\nThe best way to learn how to write your own Ghost theme is to have a look at [the source code for Casper](https://github.com/TryGhost/Casper), which is heavily commented and should give you a sense of how everything fits together.\\n\\n- `default.hbs` is the main template file, all contexts will load inside this file unless specifically told to use a different template.\\n- `post.hbs` is the file used in the context of viewing a post.\\n- `index.hbs` is the file used in the context of viewing the home page.\\n- and so on\\n\\nWe've got [full and extensive theme documentation](http://themes.ghost.org/docs/about) which outlines every template file, context and helper that you can use.\\n\\nIf you want to chat with other people making Ghost themes to get any advice or help, there's also a **themes** section on our [public Ghost forum](https://forum.ghost.org/c/themes).\"}]],\"sections\":[[10,0]]}",
|
||||
"html": "<p>Creating a totally custom design for your publication</p>\n<p>Ghost comes with a beautiful default theme called Casper, which is designed to be a clean, readable publication layout and can be easily adapted for most purposes. However, Ghost can also be completely themed to suit your needs. Rather than just giving you a few basic settings which act as a poor proxy for code, we just let you write code.</p>\n<p>There are a huge range of both free and premium pre-built themes which you can get from the <a href=\"http://marketplace.ghost.org\">Ghost Theme Marketplace</a>, or you can simply create your own from scratch.</p>\n<p><a href=\"http://marketplace.ghost.org\"><img src=\"https://static.ghost.org/v1.0.0/images/marketplace.jpg\" alt=\"marketplace\"></a></p>\n<blockquote>\n<p>Anyone can write a completely custom Ghost theme, with just some solid knowledge of HTML and CSS</p>\n</blockquote>\n<p>Ghost themes are written with a templating language called handlebars, which has a bunch of dynamic helpers to insert your data into template files. Like <code>{{author.name}}</code>, for example, outputs the name of the current author.</p>\n<p>The best way to learn how to write your own Ghost theme is to have a look at <a href=\"https://github.com/TryGhost/Casper\">the source code for Casper</a>, which is heavily commented and should give you a sense of how everything fits together.</p>\n<ul>\n<li><code>default.hbs</code> is the main template file, all contexts will load inside this file unless specifically told to use a different template.</li>\n<li><code>post.hbs</code> is the file used in the context of viewing a post.</li>\n<li><code>index.hbs</code> is the file used in the context of viewing the home page.</li>\n<li>and so on</li>\n</ul>\n<p>We've got <a href=\"http://themes.ghost.org/docs/about\">full and extensive theme documentation</a> which outlines every template file, context and helper that you can use.</p>\n<p>If you want to chat with other people making Ghost themes to get any advice or help, there's also a <strong>themes</strong> section on our <a href=\"https://forum.ghost.org/c/themes\">public Ghost forum</a>.</p>",
|
||||
"mobiledoc": "{\"version\":\"0.3.1\",\"markups\":[],\"atoms\":[],\"cards\":[[\"card-markdown\",{\"cardName\":\"card-markdown\",\"markdown\":\"Creating a totally custom design for your publication\\n\\nGhost comes with a beautiful default theme called Casper, which is designed to be a clean, readable publication layout and can be easily adapted for most purposes. However, Ghost can also be completely themed to suit your needs. Rather than just giving you a few basic settings which act as a poor proxy for code, we just let you write code.\\n\\nThere are a huge range of both free and premium pre-built themes which you can get from the [Ghost Theme Marketplace](http://marketplace.ghost.org), or you can simply create your own from scratch.\\n\\n[](http://marketplace.ghost.org)\\n\\n> Anyone can write a completely custom Ghost theme, with just some solid knowledge of HTML and CSS\\n\\nGhost themes are written with a templating language called handlebars, which has a bunch of dynamic helpers to insert your data into template files. Like `{{author.name}}`, for example, outputs the name of the current author.\\n\\nThe best way to learn how to write your own Ghost theme is to have a look at [the source code for Casper](https://github.com/TryGhost/Casper), which is heavily commented and should give you a sense of how everything fits together.\\n\\n- `default.hbs` is the main template file, all contexts will load inside this file unless specifically told to use a different template.\\n- `post.hbs` is the file used in the context of viewing a post.\\n- `index.hbs` is the file used in the context of viewing the home page.\\n- and so on\\n\\nWe've got [full and extensive theme documentation](https://docs.ghost.org/api/handlebars-themes/) which outlines every template file, context and helper that you can use.\\n\\nIf you want to chat with other people making Ghost themes to get any advice or help, there's also a **themes** section on our [public Ghost forum](https://forum.ghost.org/c/themes).\"}]],\"sections\":[[10,0]]}",
|
||||
"html": "<p>Creating a totally custom design for your publication</p>\n<p>Ghost comes with a beautiful default theme called Casper, which is designed to be a clean, readable publication layout and can be easily adapted for most purposes. However, Ghost can also be completely themed to suit your needs. Rather than just giving you a few basic settings which act as a poor proxy for code, we just let you write code.</p>\n<p>There are a huge range of both free and premium pre-built themes which you can get from the <a href=\"http://marketplace.ghost.org\">Ghost Theme Marketplace</a>, or you can simply create your own from scratch.</p>\n<p><a href=\"http://marketplace.ghost.org\"><img src=\"https://static.ghost.org/v1.0.0/images/marketplace.jpg\" alt=\"marketplace\"></a></p>\n<blockquote>\n<p>Anyone can write a completely custom Ghost theme, with just some solid knowledge of HTML and CSS</p>\n</blockquote>\n<p>Ghost themes are written with a templating language called handlebars, which has a bunch of dynamic helpers to insert your data into template files. Like <code>{{author.name}}</code>, for example, outputs the name of the current author.</p>\n<p>The best way to learn how to write your own Ghost theme is to have a look at <a href=\"https://github.com/TryGhost/Casper\">the source code for Casper</a>, which is heavily commented and should give you a sense of how everything fits together.</p>\n<ul>\n<li><code>default.hbs</code> is the main template file, all contexts will load inside this file unless specifically told to use a different template.</li>\n<li><code>post.hbs</code> is the file used in the context of viewing a post.</li>\n<li><code>index.hbs</code> is the file used in the context of viewing the home page.</li>\n<li>and so on</li>\n</ul>\n<p>We've got <a href=\"https://docs.ghost.org/api/handlebars-themes/\">full and extensive theme documentation</a> which outlines every template file, context and helper that you can use.</p>\n<p>If you want to chat with other people making Ghost themes to get any advice or help, there's also a <strong>themes</strong> section on our <a href=\"https://forum.ghost.org/c/themes\">public Ghost forum</a>.</p>",
|
||||
"amp": "1",
|
||||
"plaintext": "Creating a totally custom design for your publication\n\nGhost comes with a beautiful default theme called Casper, which is designed to\nbe a clean, readable publication layout and can be easily adapted for most\npurposes. However, Ghost can also be completely themed to suit your needs.\nRather than just giving you a few basic settings which act as a poor proxy for\ncode, we just let you write code.\n\nThere are a huge range of both free and premium pre-built themes which you can\nget from the Ghost Theme Marketplace [http://marketplace.ghost.org], or you can\nsimply create your own from scratch.\n\n [http://marketplace.ghost.org]\n\nAnyone can write a completely custom Ghost theme, with just some solid knowledge\nof HTML and CSS\n\nGhost themes are written with a templating language called handlebars, which has\na bunch of dynamic helpers to insert your data into template files. Like \n{{author.name}}, for example, outputs the name of the current author.\n\nThe best way to learn how to write your own Ghost theme is to have a look at \nthe\nsource code for Casper [https://github.com/TryGhost/Casper], which is heavily\ncommented and should give you a sense of how everything fits together.\n\n * default.hbs is the main template file, all contexts will load inside this\n file unless specifically told to use a different template.\n * post.hbs is the file used in the context of viewing a post.\n * index.hbs is the file used in the context of viewing the home page.\n * and so on\n\nWe've got full and extensive theme documentation\n[http://themes.ghost.org/docs/about] which outlines every template file,\ncontext and helper that you can use.\n\nIf you want to chat with other people making Ghost themes to get any advice or\nhelp, there's also a themes channel on our public Ghost forum\n[https://slack.ghost.org].",
|
||||
"plaintext": "Creating a totally custom design for your publication\n\nGhost comes with a beautiful default theme called Casper, which is designed to\nbe a clean, readable publication layout and can be easily adapted for most\npurposes. However, Ghost can also be completely themed to suit your needs.\nRather than just giving you a few basic settings which act as a poor proxy for\ncode, we just let you write code.\n\nThere are a huge range of both free and premium pre-built themes which you can\nget from the Ghost Theme Marketplace [http://marketplace.ghost.org], or you can\nsimply create your own from scratch.\n\n [http://marketplace.ghost.org]\n\nAnyone can write a completely custom Ghost theme, with just some solid knowledge\nof HTML and CSS\n\nGhost themes are written with a templating language called handlebars, which has\na bunch of dynamic helpers to insert your data into template files. Like \n{{author.name}}, for example, outputs the name of the current author.\n\nThe best way to learn how to write your own Ghost theme is to have a look at \nthe\nsource code for Casper [https://github.com/TryGhost/Casper], which is heavily\ncommented and should give you a sense of how everything fits together.\n\n * default.hbs is the main template file, all contexts will load inside this\n file unless specifically told to use a different template.\n * post.hbs is the file used in the context of viewing a post.\n * index.hbs is the file used in the context of viewing the home page.\n * and so on\n\nWe've got full and extensive theme documentation\n[https://docs.ghost.org/api/handlebars-themes/] which outlines every template file,\ncontext and helper that you can use.\n\nIf you want to chat with other people making Ghost themes to get any advice or\nhelp, there's also a themes category on our public Ghost forum\n[https://forum.ghost.org/c/themes].",
|
||||
"feature_image": "https://static.ghost.org/v1.0.0/images/design.jpg",
|
||||
"featured": 0,
|
||||
"page": 0,
|
||||
|
|
|
@ -12,7 +12,7 @@ The default theme for [Ghost](http://github.com/tryghost/ghost/). This is the la
|
|||
|
||||
Ghost uses a simple templating language called [Handlebars](http://handlebarsjs.com/) for its themes.
|
||||
|
||||
We've documented our default theme pretty heavily so that it should be fairly easy to work out what's going on just by reading the code and the comments. Once you feel comfortable with how everything works, we also have full [theme API documentation](https://themes.ghost.org) which explains every possible Handlebars helper and template.
|
||||
We've documented our default theme pretty heavily so that it should be fairly easy to work out what's going on just by reading the code and the comments. Once you feel comfortable with how everything works, we also have full [theme API documentation](https://docs.ghost.org/api/handlebars-themes/) which explains every possible Handlebars helper and template.
|
||||
|
||||
**The main files are:**
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue