{
"version": "https://jsonfeed.org/version/1",
"title": "squido documentation",
"home_page_url": "https://squido-docs.markmoffat.com",
"feed_url": "https://squido-docs.markmoffat.com/json",
"description": "Squido documentation - A dead-simple Node.js static HTML website generator for super fast static websites which are easier to develop, more secure and dirt cheap to host.",
"items": [
{
"id": "https://squido-docs.markmoffat.com/getting-started/",
"content_html": "\n
squido is a dead simple static website builder which can be hosted anywhere for super fast websites and very little effort.
The idea is to be a no-code setup and have everything you need to run and host a website. You simply do the writing and customization of style and layout.
Simply install the squido cli module globally in order to build and manage your static site.
From Github (preferred for latest version)
\n$ npm i -g https://github.com/mrvautin/squido.git\n\nFrom npm
\n$ npm install -g squido\n\nWith Yarn
\n$ yarn global add squido\n\nMake your squido website directory:
$ mkdir my-squido-website\n\nEnter your new squido website directory:
$ cd my-squido-website\n\nSetup a new squido website from defaults
$ squido new\n\nMake your squido website directory:
$ mkdir my-squido-website\n\nEnter your new squido website directory:
$ cd my-squido-website\n\nGet started building your squido website structure.
The example we will use below is our blog example. There is also a documentation website example you can use.
\n$ git clone https://github.com/mrvautin/squido-blog-example my-squido-website\n\nReplace my-squido-website with your new website directory name
Enter your new squido website directory:
$ cd my-squido-website\n\nRun the following command to build, clean, serve and watch for changes:
\n$ squido serve -b -w -c\n\nYou can then visit your website here:
\nhttp://localhost:4965\n\n\n\n\n
Clean= removes everything in your/builddirectory.
\n\n\n
Serve= starts a web server so you can view your website.
Whilst it's best and easiest (depending on the user) to use squido with Git to manage deployment and source control. If you don't want to use Git you can use our Post Build tasks to easily deploy and manage your website.




$ git remote add origin https://github.com/user/repo.git\n\n$ git remote -v\n# Verify new remote\n> origin https://github.com/user/repo.git (fetch)\n> origin https://github.com/user/repo.git (push)\n\n/source/posts/hello-world.markdown\ntitle: Hello World\npermalink: hello-world\ndescription: Hello World\ndate: '2021-03-10 01:59:00'\n\n$ git add .\n\n$ git commit -m "First commit"\n\n$ git push\n\nSetup the deploy/hosting.
\nBlog style: https://squido-blog.markmoffat.com
\nDocumentation style: This website
\nTraditional website: https://squido.markmoffat.com
\n", "url": "https://squido-docs.markmoffat.com/getting-started/", "title": "Getting started", "summary": "Getting started with squido", "date_modified": "2021-03-10T01:59:00.000Z" }, { "id": "https://squido-docs.markmoffat.com/structure/", "content_html": "You can start by grabbing everything in the /source directory of here.
The structure will look something like:
\n
The /<source_dir> directory is the default directory for all the source files. You can change by adding another directory in the sourceDir of the config.js file.
| File name | \nUsage | \n
|---|---|
index.hbs | \nThe root of your website. The first page which will be rendered. | \n
post.hbs | \nWill render the contents of the .markdown files in /<source_dir>/posts | \n
page.hbs | \nDisplayed at /page/x for the pagination of posts | \n
tag.hbs | \nDisplayed at /tag/x for the collection of posts by tag | \n
Your posts go in the /<source_dir>/posts directory. You will have .markdown files for each post/page you want.
The content directory contains the files used for your website. Eg: Stylesheets, images, javascript files etc.
The CLI comes with a few commands.
\nUsage: cli [options] [command]\n\nOptions:\n -V, --version output the version number\n -h, --help output usage information\n\nCommands:\n build [options] Builds your website\n clean Clean your website build\n serve [options] Serves website\n\nThe build command has the following options:
Usage: build [options]\n\nBuilds your website\n\nOptions:\n -c --clean Cleans build directory\n -h, --help output usage information\n\nThe import command allows you to import content from external sources. It has the following options:
Usage: import [options]\n\nImport from external sources\n\nOptions:\n -f, --file <path> Specify file to import\n -t, --type <type> Specify the type of file to import. Eg: wordpress or ghost\n -h, --help output usage information\n\nThe clean command has the following options:
Usage: clean [options]\n\nClean your website build\n\nOptions:\n -h, --help output usage information\n\nThe serve command has the following options:
Usage: serve [options]\n\nServes website\n\nOptions:\n -w --watch Watches for changes\n -b --build Builds on start\n -c --clean Cleans build directory\n -h, --help output usage information\n\nThis command sets up a new website from our blog template.
\nThe new command has the following options:
Usage: new [options]\n\nSets up a new website\n\nOptions:\n -h, --help output usage information\n\n",
"url": "https://squido-docs.markmoffat.com/usage-commands/",
"title": "Usage / Commands",
"summary": "Getting started with the squido commands",
"date_modified": "2021-03-08T01:57:00.000Z"
},
{
"id": "https://squido-docs.markmoffat.com/configuration/",
"content_html": "An example config can be seen below. You can see that you can specify different values for different environments you run. development and production are examples but they need to match up with whatever NODE_ENV is set. If one is not set, the default is development.
const config = {\n development: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'http://localhost:4965',\n sourcesExt: 'markdown',\n templateEngine: 'hbs',\n templateConfig: {},\n sourceDir: 'source',\n contentDir: 'content',\n buildDir: 'build',\n summaryLength: 250,\n port: 4965,\n pagination: true,\n postPerPage: 8\n },\n production: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'http://example.com',\n sourcesExt: 'markdown',\n templateEngine: 'hbs',\n templateConfig: {},\n sourceDir: 'source',\n contentDir: 'content',\n buildDir: 'build',\n summaryLength: 250,\n port: 4965,\n pagination: true,\n postPerPage: 8,\n postBuild: [\n {\n name: 'zip',\n options: {}\n }\n ]\n }\n};\n\nmodule.exports = config;\n\n| Config | \nUsage | \n
|---|---|
name | \nUsed in default templates for <title> and meta tags for homepage | \n
description | \nUsed in default templates for meta tags for homepage | \n
baseUrl | \nUsed for URL building purposes. Would set this to https://example.com | \n
sourcesExt | \nThe file extension for your markdown posts | \n
templateEngine | \nThe template engine to use. Possible values are: hbs, ejs or pug | \n
sourceDir | \nThe directory where your markdown posts reside | \n
contentDir | \nThe directory where your Javascript, CSS, images and other assets reside | \n
buildDir | \nThe directory where the static HTML files and assets are placed after building | \n
summaryLength | \nThe length of the post summary which is available in the meta data of the post | \n
port | \nThe port used when running squido serve | \n
pagination | \nThis controls whether you want squido to paginate your posts | \n
postPerPage | \nThis controls how many posts appear per page | \n
postBuild | \nControls any post build tasks you wish to run. See here | \n
You can use any of the config values in your template files using {{config.<option>}}. Eg: For example {{config.baseUrl}}.
The templateEngine config allows for the setting of which template engine to use - either: hbs, ejs or pug is allowed. The templateConfig object allows for the passing of configurations and is used when ejs or pug is set for the templateEngine. See here for available ejs options and here or pug.
Posts are essentially pages or blog posts or whatever you like. The content of the post/page is contained in markdown files within the /source/posts folder. The post markdown or contents is rendered using the post.hbs template file. You can edit this any which way your want. See templates for more information.
Posts have a meta data component at the top of the file which directs how the file is built. The meta data is yaml formatted and sits between two --- tags. Eg:
\ntitle: Caede virides oculos armentis\npermalink: caede-virides-oculos-armentis\ndescription: Caede virides oculos armentis\ndate: '2021-03-11 19:17:00'\ntemplate: post.hbs\nignore: true\nhidden: false\ntags: \n - alter\n - tradere\n\nRequired fields are: 'title', 'permalink', 'description' and 'date'
\nYou can add any data values your like but the example layouts uses the title and description for SEO for page title.
New meta data values can be access in the layouts using {{meta.<new value>}}.
The permalink is required. Its used to build the URL for your website: Eg. The above will output a post at: https://example.com/caede-virides-oculos-armentis
The visible and hidden are optional tags for controlling the visibility of posts. Defaults is "true" or visible.
visible: If set to false, the post will not be in the pagination and won't show on the index page.hidden: If set to true, the post will not be in the sitemap and RSS feeds.The default template file name for posts is post.hbs but this can be overwritten per post by adding a template meta value to your post. Eg:
\ntemplate: template-name.hbs\n\n",
"url": "https://squido-docs.markmoffat.com/posts/",
"title": "Posts",
"summary": "Getting started with the squido post structure",
"date_modified": "2021-03-06T01:55:00.000Z"
},
{
"id": "https://squido-docs.markmoffat.com/markdown/",
"content_html": "squido uses CommonMark spec to process the markdown formatted posts.
A quick syntax summary to get your started:
\n| Type | \nRenders | \n
|---|---|
| Italic or _Italic_ | \nItalic | \n
| *Bold* or _Bold_ | \nBold | \n
| # Heading 1 | \nHeading 1 | \n
| # Heading 2 | \nHeading 2 | \n
| # Heading 3 | \nHeading 3 | \n
| [Link](https://a.com) | \nLink | \n
| [Image](https://url/a.png) | \n|
| > Blockquote | \nBlockquote | \n
| * List * List * List or - List - List - List | \n
| \n
1. List 2. Listor 1) List 2) List 3) List | \n
| \n
| Horizontal rule: --- or *** | \nHorizontal rule: | \n
| `Inline code` with backticks | \nInline code with backticks | \n
| ``` javascript const test = () => { console.log('test'); }; ``` | \n const test = () => { | \n
You can play around with the Markdown Playground here.
\nsquido uses Highlight.js for code highlighting. This means you can use the code block example above with code wrapped in ``` backticks. You can specify the language by adding the language for your code block.
For example, adding this:
\n``` javascript
function test(p1, p2) {
console.log('test');
};
```
Renders this:
\nfunction test(p1, p2) {\n console.log('test');\n};\n\nYou can add any HTML attributes including ID's and classes by adding {attribute} to your Markdown syntax.
Adding a class to a header (style-me is the class):
# header {.style-me}
Adding a data-toggle attribute to a paragraph:
paragraph {data-toggle=modal}
You can also use this on tables with multiple classes. Eg (note the empty line under the table):
\nMy table | Header \n-------------- | ----------\nTable | Contents\n\n{.table .table-hover .table-bordered}\n\nRenders this:
\n| My table | \nHeader | \n
|---|---|
| Table | \nContents | \n
All headings are automatically rendered as # anchors to hyperlink (skip) to sections within a page / post. This means you add the /#heading-name to the URL to automatically jump to that heading.
For example:\nhttps://squido-docs.markmoffat.com/markdown/#playground
\n", "url": "https://squido-docs.markmoffat.com/markdown/", "title": "Markdown", "summary": "Getting started with the squido markdown format", "date_modified": "2021-03-05T01:55:00.000Z" }, { "id": "https://squido-docs.markmoffat.com/templates/", "content_html": "Templates use Handlebars formatting and the {{}} syntax, EJS or pug. This guide will show Handlebars formatting. Documentation on changing the templateEngine can be found here.
Handlebars formatting.\nDocumentation on changing the templateEngine can be found here.\nThe template files needed by default are:
\nindex.hbspost.hbspage.hbstag.hbs404.hbsAlso needed is a layout file called layout.hbs located here: /source/layouts/layout.hbs. This file drives the main layout of the page including the <html>, <head>, <body> etc tags.
Accessible on all layout and templates files is your post meta using {{meta.<property>}} and your config.js object. You can access that using {{config.<propery>}}.
This is the entry point of your website, the index.html in the root of your build directory.
You will have access to a list of posts which you may want to display if building a blog or you may want to manually create a landing page for your website. The choice is yours.
\nIf you were to render your posts you may want to do something like where {{#each posts}} is looping our list of posts:
<div class="row">\n {{#each posts}}\n <div class="article">\n <h2>\n <a href="/{{this.permalink}}/">{{this.title}}</a> \n </h2>\n {{this.summary}}\n </div>\n {{/each}}\n</div>\n\nDepending on if you have pagination set to true in your config, you will either get a full list of articles or a paginated list. See pagination for more info.
This is the rendering of the post or the markdown content at the permalink set. Eg: mydomain.com/permalink-value.
To render the body of the markdown file you will need to add the following tag to your template: {{{body}}}
You will have access to the full meta values of the page but can also access the title using {{title}}. Depending on whether you included tags in the meta data of the markdown file, you will also get a tags object you can loop through to display tags. See tags for more info.
A simple post page could be:
\n<div class="row">\n <div class="col-md-8 offset-md-2 mb-5">\n <div class="mt-5">\n <h1>{{title}}</h1>\n {{{body}}}\n </div>\n </div>\n</div>\n\nThis is the pagination aspect of your website. This template is used at /page/x (where x is the page number). If you are creating a blog which will have pagination this could look very similar to the index.hbs which shows all your articles/posts. Similar to the index.hbs you will get a post object with the posts you should render if you are doing pagination.
A simple template could look like:
\n<div class="row">\n {{#each posts}}\n <div class="col-xs-12 col-sm-3 mb-4 d-flex align-items-stretch">\n <div class="card shadow-sm">\n <div class="card-body">\n <p class="card-text">\n <h2>\n <a href="/{{this.permalink}}/">{{this.title}}</a> \n </h2>\n {{this.summary}}\n </p>\n <div class="d-flex justify-content-between align-items-center">\n <a class="btn btn-outline-secondary" href="/{{this.permalink}}/">Read more..</a>\n </div>\n </div>\n </div>\n </div>\n {{/each}}\n</div>\n\nThis is the tag page which is generated from the tags set in your post markdown. A page is create for each tag you use in your markdown files and is accessible at: /tag/<tag-value>. Keep this in mind when setting tag values where you will want to give permalink type values for pretty URLs.
A simple template could look like:
\n<div class="row">\n <h1>Tag: {{tag}}</h1>\n {{#each posts}}\n <div class="col-xs-12 col-sm-3 mb-4 d-flex align-items-stretch">\n <div class="card shadow-sm">\n <div class="card-body">\n <p class="card-text">\n <h2>\n <a href="/{{this.permalink}}">{{this.title}}</a> \n </h2>\n {{this.summary}}\n </p>\n <div class="d-flex justify-content-between align-items-center">\n <a class="btn btn-outline-secondary" href="/{{this.permalink}}/">Read more..</a>\n </div>\n </div>\n </div>\n </div>\n {{/each}}\n</div>\n\nHopefully this one is obvious. If at any point a page isn't found or a URL is mistyped this 404 page will be rendered.
\nA simple template:
\n<div class="row">\n <div class="col-md-6 offset-md-3 mt-5 mb-3">\n <div class="text-center">\n <img src="/content/images/squido.svg" alt="" width="200" height="200" alt="squido logo" class="img-fluid">\n </div>\n <h1 class="mt-5 text-center">404 - Page not found</h1>\n </div>\n</div>\n\nYou can include local Stylesheets and Javascript files in the layout.hbs file by using path starting with /content and then wherever you have placed the file. Eg: /content/stylesheets/<myfile>.css.
The layout.hbs also includes a config property named fileEnv ({{config.fileEnv}}) which will return either nothing or .min if you have set the NODE_ENV to production. This is useful if you are wanting to use the un-minified CSS or JS file when troubleshooting/developing your website and using the minified version when in production.
Example usage:
\n<link rel="stylesheet" href="/content/stylesheets/style{{config.fileEnv}}.css">\n<script src="/content/javascripts/site{{config.fileEnv}}.js"></script>\n\nWithin a post you have access to a tag array which contains all the tags for that post. You may want to iterate through that array to link to the /tag/<tag-value> URL. For example:
{{#if tags}}\n<div class="row">\n <div class="col-md-8 offset-md-2 mb-5">\n <h5 class="text-muted">Tags:</h5>\n {{#each tags}}\n <a href="/tag/{{this}}/">{{this}}</a> |\n {{/each}}\n </div>\n</div>\n{{/if}}\n\nIf pagination is set to true in your config.js file, the post object available on all templates will be paginated to the postPerPage value you set in your config.js. Eg: 10 posts and postPerPage set to 5 will create 2 pages. 1, the index page and /page/1 as the first paginated page.
You will also get a shouldPaginate variable which will return true or false depending on whether there is more posts than can be displayed - eg: you should paginate.
An example displaying the pagination might look like:
\n{{!-- Pagination --}}\n{{#if config.pagination}}\n{{#if shouldPaginate}}\n<div class="row">\n <div class="col-xs-12 col-sm-12 mb-4 text-center">\n <p class="text-muted">Page {{page}} of {{pages}}</p>\n <div class="btn-group" role="group">\n {{#if prevPage }}\n <a href="/page/{{prevPage}}/" class="btn btn-outline-secondary">« Prev Page</a>\n {{/if}}\n {{#if nextPage }}\n <a href="/page/{{nextPage}}/" class="btn btn-outline-secondary">Next Page »</a>\n {{/if}}\n </div>\n </div>\n</div>\n{{/if}}\n{{/if}}\n\nsquido supports the adding of custom data to your website. This function allows for yaml, json or text formatted files to be parsed and added to the data available in your templates.
Adding custom data is as simple as adding the following Array of Objects to your config.js file. You will need to have the following properties:
name = The name which is accessible in your template. Eg: A name of swagger will mean the contents of the file is accessible at data.swagger.type = Supported types are: yaml, json or textfile = The file path in relation to your sourceDir. In the example below the file is located: source/swagger.yamlA full example below:
\nconst config = {\n development: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'http://localhost:4965',\n sourcesExt: 'markdown',\n templateEngine: 'hbs',\n data: [\n {\n name: 'swagger',\n type: 'yaml',\n file: 'swagger.yaml'\n }\n ],\n sourceDir: 'source',\n buildDir: 'build',\n ...\n }\n}\n\nsquido supports Swagger using our custom data functionality. You can use this to setup super fast static API documentation. Simply grab our demo swagger.hbs template and setup a post like the following where template: swagger.hbs is the path to the Swagger template file in your sourceDir:
\ntitle: Swagger API docs\npermalink: api\ndescription: Swagger API Docs\ndate: '2021-05-11 19:17:00'\ntemplate: swagger.hbs\nvisible: false\nhidden: false\n\nThen setup your config.js to include the Swagger data like:
const config = {\n development: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'http://localhost:4965',\n sourcesExt: 'markdown',\n templateEngine: 'hbs',\n data: [\n {\n name: 'swagger',\n type: 'yaml',\n file: 'swagger.yaml'\n }\n ],\n sourceDir: 'source',\n buildDir: 'build',\n ...\n }\n}\n\n\n\nWhere
\nswaggerFileis the name of yourswagger.yamlfile in relation to yoursourceDir. Note: thetypecan also be set tojsonfor a JSON formatted Swagger file.
Partials can be created in /source/partials and can be used in layout and other template files.
Once a file is created you can add it to your template using:
\n{{> header}}\n\n\n\nWhere
\nheaderis the name of the fileheader.hbslocated:/source/partials/header.hbs
ejs handling of partials is a little more flexible. You can setup your config using the templateConfig.views option with the directory where the partials will exist. Eg:
const config = {\n development: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'http://localhost:4965',\n sourcesExt: 'markdown',\n templateEngine: 'ejs',\n templateConfig: {\n views: ['source/partials']\n },\n sourceDir: 'source',\n buildDir: 'build',\n ...\n }\n}\n\n\n\nNote: The
\ntemplateConfig.viewstakes an array of paths
Pug partials is super easy. You need to setup the root by setting the templateConfig.basedir to __dirname. Eg:
const config = {\n development: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'http://localhost:4965',\n sourcesExt: 'markdown',\n templateEngine: 'pug',\n templateConfig: {\n basedir: __dirname\n },\n sourceDir: 'source',\n buildDir: 'build',\n ...\n }\n}\n\nThen in a template you can include a partial by adding the following: include /source/partials/header.pug
A website sitemap is automatically built and can be found at /sitemap.xml. Eg: example.com/sitemap.xml
RSS/Atom/JSON feeds are also automatically built and can be found at:
\n/rss. Eg: example.com/rss/atom. Eg: example.com/atom/json. Eg: example.com/jsonPlugins can be created if core functionality is not included or customization is required. Plugins run at the final step of the build so you can override any of the existing steps if needed.
\nPlugins are Javascript files within /<source dir>/plugins/<plugin name>.js.
The plugin file needs to export a function named run. For example:
const run = (opts) => {\n /* code in here */\n console.log('opts', opts);\n};\n\nmodule.exports = {\n run\n};\n\nAdding plugins to your /config.js file is simple by adding the plugin to the plugins array:
const config = {\n development: {\n ...\n plugins: [\n {\n name: 'search',\n options: {}\n }\n ]\n }\n}\n\nname: the name of the plugin. This also needs to match the name of the file. Eg: /source/plugins/search.js
options: An arg object passed into the plugin.
You can access environment variables in your plugins using the process.squido.envVars object.
You might want to do something different in your plugin based on a environment variable you've set with you hosting provider.
\nAn example plugin:
\nconst run = (opts) => {\n const config = process.squido;\n\n let toPrint = 'Hello squido';\n\n if(config.envVars.helloMessage){\n toPrint = config.envVars.helloMessage;\n }\n\n console.log(`Hello ${toPrint}`);\n};\n\nmodule.exports = {\n run\n};\n\nEg: For Netlify you would set a variable named helloMessage to World (for example above) and the plugin would then console.log Hello World if the environment variable is set and Hello squido when nothing is set.
squido allows the importing of content from Ghost and Wordpress.
We will use the import command.
\nTo import data, you first need to export your data from your Ghost site:
\ncog icon at the bottom of the sidebarLabsExport your contentTo import that data into squido you need to run this command from the root of your squido website:
$ squido import -f /path/to/file/ghost.json -t ghost\n\nYou will see a new folder with all your posts in Markdown format here: /imported.
You can check your files are imported correctly then move your newly imported Markdown files here: /<source dir>/posts.
To import data, you first need to export your data from your Wordpress site:
\nToolsExportExport allTo import that data into squido you need to run this command from the root of your squido website:
$ squido import -f /path/to/file/wordpress.xml -t wordpress\n\nYou will see a new folder with all your posts in Markdown format here: /imported.
You can check your files are imported correctly then move your newly imported Markdown files here: /<source dir>/posts.
You can host this website anywhere static websites are supported. Some options are https://www.netlify.com as the deployments are just dead simple.
\nSimply connect your Git repo and set the Build settings settings like below:

And set the Environment variable to align with your config.js file:

You are done. Now each push to your Git repo will trigger the build and deploy on Netlify.
\nPublishing to Github pages is easy. Simply set your config buildDir to docs and the correct baseUrl. Eg:
production: {\n name: 'squido',\n description: 'This is the blog description',\n twitterHandle: '@mrvautin',\n baseUrl: 'https://<github-username>.github.io',\n sourcesExt: 'markdown',\n sourceDir: 'source',\n buildDir: 'docs',\n summaryLength: 250,\n port: 4965,\n pagination: true,\n postPerPage: 8\n}\n\nThen simply build your website with squido build -c and push to your Github repo.
You then need to set Source to /docs as shown here and may need to change the branch.
You can then either access at your Repo URL (https://<github-username>.github.io) or a custom domain
It's very easy to publish your squido website to AWS Amplify.
New AppHost web appEdit on the build commands and ensure baseDirectory is set to /build. Eg Yaml file will look like:version: 1\nfrontend:\n phases:\n preBuild:\n commands:\n - npm ci\n build:\n commands:\n - npm run build\n artifacts:\n baseDirectory: /build\n files:\n - '**/*'\n cache:\n paths:\n - node_modules/**/*\n\nSave and deploy and wait for your website to be built!It's very easy to publish your squido website for FREE using Cloudflare pages. Free SSL, custom domain, global CDN and more and just super simple to setup.
Create new projectBegin setup
Save and deployCustom domains and you are doneDigitalocean Apps makes hosting your static HTML squido website for FREE just so bloody easy. Digitalocean Apps offers free SSL, custom domain, global CDN and more.
Github as source and choose your squido Repository:
Next
Next.Next once moreStarter for FREE hostingLaunch Starter AppView logs buttonSettings and configure your domain and moreYou are done. Enjoy your super fast hosting on the awesome Digitalocean platform!
\nPublishing your squido website to Azure Static Web Apps is very easy and low cost.
Other under Deployment details.Manage Deployment Token. Copy this token somewhere safe. It will be used later.
Repos and clone the Azure repo to your local machine. Either move your existing squido site into this local repo, or create a new squido site. Commit and push code to this Azure DevOps repoPipelines and create a new Pipeline for the project. Select Starter Pipeline and paste in the yaml template belowtrigger:\n - main\npool:\n vmImage: ubuntu-latest\nvariables:\n- name: NODE_ENV\n value: production \nsteps:\n - checkout: self\n submodules: true\n - task: AzureStaticWebApp@0\n inputs:\n app_location: '/'\n output_location: '/build'\n azure_static_web_apps_api_token: $(deployment_token)\n\nVariables then New Variabledeployment_token and paste in the Deployment Token from Step 1c. aboveThe squido admin panel is accessible after running the serve.
Running serve:
\n$ squido serve -b -c -w\n\nOpen the following in a browser: http://localhost:4965/squido
You should see:
\n
Here you can create, edit and delete any posts for you website. Once you have completed you simply need to deploy or Git commit and push to your repo.
\n", "url": "https://squido-docs.markmoffat.com/admin-editor/", "title": "Admin editor", "summary": "squido admin allows you to edit your website content straight from your browser. You can create, edit and delete posts without using a text editor.", "date_modified": "2021-02-27T01:52:00.000Z" }, { "id": "https://squido-docs.markmoffat.com/post-build-tasks/", "content_html": "Post build tasks are tasks which run after the website is built. You can configure zipping up your website, automatic deployment etc to make deploying your website faster. See configuration for information on configuring a task.
\nThe zip postBuild task simply zips all the files in your /build directory into a file called build.zip located here: /build/build.zip. You can then send/upload this file to your website host, FTP it or back it up.
An example config.js configuration is below. There are no options for this task.
production: {\n name: 'squido docs',\n description: 'Squido documentation - A dead simple static website generator',\n ...\n postBuild: [\n {\n name: 'zip',\n options: {}\n }\n ]\n ...\n}\n\nThe netlify postBuild deploys your website to Netlify without the use of Git. This task requires the zip task to also be configured before this task (see below config) as this task will upload the zip file containing your website direct to Netlify using their file upload API.
An example netlify task configuration is below. You can see the zip task is configured first:
production: {\n name: 'squido docs',\n description: 'Squido documentation - A dead simple static website generator',\n ...\n postBuild: [\n {\n name: 'zip',\n options: {}\n },\n {\n name: 'netlify',\n options: {\n siteName: 'squido test website'\n apiToken: 'my-netlify-api-token'\n }\n }\n ]\n ...\n}\n\nTo use this task you will need to obtain your apiToken from Netlify by:
Netlify here https://app.netlify.com/user/applicationsPersonal access tokens, click New access tokenconfig.js file under apiTokenAfter you run:
\n$ squido build -c\n\nThe build files of your website will first be added to a zip file, then that file is uploaded to Netlify to be built and served. You can then view your Netlify websites under the Sites tab and can control your custom domain and other settings.