New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

monoture

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

monoture

Simple blogging on Node.js

latest
Source
npmnpm
Version
0.7.0
Version published
Maintainers
1
Created
Source

Monoture

Monoture is a simple blogging application for Node.js. Easy to extend for developers and even easier to use for writers.

Features

  • Easily access content via a built in API
  • Build custom templates, themes and components using Pug and Express.js
  • Write content in Markdown and view changes in real time
  • Manage the site through the command line
  • Content is stored on-disk using NeDB (a lightweight document database)

Installation

$ npm install monoture --save

Getting Started

Monoture ships with an installation script that will set the project up;

$ monoture install

The script will create a few directories, a standard env.js environment file and register an admin user with a randomised password. Users can be added, updated and deleted via the command line (see below).

Monoture can also be started using the command line;

$ monoture run

By default this will start Monoture on http://localhost:3000. The dashboard can be accessed at http://localhost:3000/dashboard/.

Command line

monoture run

Starts an instance of the Monoture application. Handy if you're not directly accessing the internal API.

monoture install

Installs Monoture onto the parent package by creating folders, default configuration and users.

monoture user-list

Lists all registered user accounts.

monoture user-add [username] [password]

Creates a new user with the provided username and password.

monoture user-delete [username]

Deletes a user.

monoture user-pass [username] [password]

Updates the specified user with a new password.

API

Monoture exposes all the content via an external RESTful API. This is protected by a bearer token which can only be obtained after successful login.

Currently only the Post model is presented by the API;

Retrieve all posts

GET /v1/posts

Create a new post

POST /v1/posts

Update an existing post

PUT /v1/posts/:post

Delete a post

DELETE /v1/posts/:post

Monoture also provides an internal API that allows developers to implement custom functionality and themes;

setTheme(package)

Allows a custom theme to be passed through and bound to the underlying Express.js application.

run()

Starts Monoture, similar to running monoture run from the command line.

Theming

Monoture uses Pug by default for page layouts and theming. Monoture is configured with multiple view and public directories, which allows templates to be easily extended and overwritten.

Monoture will always check the main package first, and then fallback to the theme directories.

Typically a theme must implement a main home page and a post page. See monoture-theme for reference.

Screenshots

Dashboard

dashboard

Editor

editor

Known issues

  • Windows 10 users may need to install Microsoft Visual C++ Build Tools in order to run node-gyp

Keywords

content

FAQs

Package last updated on 26 Feb 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts