Skip to content

Instantly share code, notes, and snippets.

@gistfrojd
Last active March 18, 2021 17:09
Show Gist options
  • Save gistfrojd/5fcd3b70949ac6376f66 to your computer and use it in GitHub Desktop.
Save gistfrojd/5fcd3b70949ac6376f66 to your computer and use it in GitHub Desktop.
README.md example (this file has moved to https://github.com/Frojd/Manual)

Project name

A short introduction to your project here, what it is built in and what cms/framework etc it is using.

Requirements

This section is optional if there isn't any special dependencies. Else a bulletlist will suffice, e g:

  • Node.js
  • Mongodb
  • Amazon S3 access

Installation

A quick guide on how to install your project. For example:

  1. Download the repo to your webserver
  2. Run npm install
  3. Install database
  4. Edit config.conf with your database settings
  5. Visit your new site!

Quick start

This section is optional, however for librarys or plugins a quick start is very handy.

  1. npm install myapp

  2. app.js

     var myApp = new MyApp();
     myApp.run(
         'hello', 
         function() { 
             console.log("my callback") 
         }
     ); 
    
  3. node app.js

  4. Output will be "hello"

API

This section is optional, but if your project is a library or plugin there should be some examples here explaining how to implement it and how to use it. There should also be explanations for functions/options/parameters in this section.

Hello World example

In the head section of your index.html page include this:

<script>    
    console.log("Hello World");
</script>

More advanced example

This is a more advanced example on how to implement the libary. In the head section of your webpage include this:

<script>
    var myLib = new SuperMyLib({
        output: "Hello World",
        selector: ".someClass"
    });
    
    myLib.init();
</script>

Then add an element in your webpage that have the class "someClass".

<div class="someClass"></div>

Code guide

If your project is using any special cases then they should be explained here.

Example case controllers

All controllers must inherit from IBaseController to maintain compability within the site.

Contributing

This section is for open source projects. Write how a 3rd party can contribute with this project to help out.

Licence

If there is a licence, specifically for open source projects, it should be here. Else this section can be removed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment