Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

generator-django-rest

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

generator-django-rest

A Yeoman generator for a Django REST API that makes you efficient, includes features you need in a typical modern web app, yet keeps things simple.

  • 0.4.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
13
increased by333.33%
Maintainers
1
Weekly downloads
 
Created
Source

generator-django-rest npm Build Status GitHub license

A Yeoman generator for a Django REST API (and optionally a React SPA) that makes you efficient, includes features you need in a typical modern web app, yet keeps things simple.

Note: the project is still considered to be in beta until I get a chance to test it on more apps. That said, I am using it in my own projects :)

Features

The philosophy is to include features useful across projects that are tedious to set up from scratch. Some of the cool ones are:

  • quick to launch 🚀 – start a new project and deploy it to Heroku in 3 commands:

      yo django-rest
      ./scripts/devsetup.sh
      ./scripts/deploy.sh
    
  • productive ⚡️ – start the Django, DB & optionally frontend dev servers easily

      ./scripts/dev.sh
    
  • sane logging 📜 – defaults to fail nicely

  • modern JS 🦄 – serve static files on / using django-spa & Whitenoise for nice single-page apps using React / Angular2 / Vue…

  • self-sufficient ⛵️ - option to automatically set up a create-react-app frontend for you with all the integration settings under the mantra one app, one repo, one dyno

  • 12-factor config 🤓 – environment variable configuration

    • define a variable in .env for dev e.g. REDIS_URL=redis://localhost:6379/0
    • use it in settings.py, e.g. CELERY_RESULT_BACKEND = env('REDIS_URL')
    • set variables on the prod server (just works™ with Redis on Heroku)
  • batteries included 🔋

    • Celery with a Redis backend – cause you'll need an async task queue
    • Backblaze B2 media file storage backend (optional)
  • familiar 🐶 – check out the rough project file layout, it's much like django-admin startproject myproject would set it up (only repeats the project name twice, i.e. ~/code/myproject/myproject/settigns.py)

Getting Started

To begin, you need to install node.js. Once you have that, you need Yeoman pre-installed. Yeoman lives in the npm package repository. You only have to ask for him once, then he packs up and moves into your hard drive.

npm install -g yo

Then, we need the django-rest generator, i.e. plug-in. You install generator-django-rest from npm.

npm install -g generator-django-rest

Finally, for every new project you would initiate the generator in an empty folder.

mkdir myproject
cd myproject
yo django-rest

Now check HACKING.md for extra instructions.

License

MIT

Keywords

FAQs

Package last updated on 03 Aug 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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc