From ec4f219ecb7a5e43d0353633fac4dac42d0ee492 Mon Sep 17 00:00:00 2001 From: Trey Hunner Date: Mon, 27 Apr 2015 21:12:31 -0700 Subject: Fixed #22463 -- Added code style guide and JavaScript linting (EditorConfig and ESLint) --- docs/internals/contributing/writing-code/coding-style.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'docs/internals/contributing/writing-code/coding-style.txt') diff --git a/docs/internals/contributing/writing-code/coding-style.txt b/docs/internals/contributing/writing-code/coding-style.txt index 2aa967c88d..54c2bd47e2 100644 --- a/docs/internals/contributing/writing-code/coding-style.txt +++ b/docs/internals/contributing/writing-code/coding-style.txt @@ -7,6 +7,11 @@ Please follow these coding standards when writing code for inclusion in Django. Python style ------------ +* Please conform to the indentation style dictated in the ``.editorconfig`` + file. We recommend using a text editor with `EditorConfig`_ support to avoid + indentation and whitespace issues. The Python files use 4 spaces for + indentation and the HTML files use 2 spaces. + * Unless otherwise specified, follow :pep:`8`. Use `flake8`_ to check for problems in this area. Note that our ``setup.cfg`` @@ -286,4 +291,11 @@ Miscellaneous change to the ``AUTHORS`` file in your patch if you make more than a single trivial change. +JavaScript style +---------------- + +For details about the JavaScript code style used by Django, see +:doc:`javascript`. + +.. _editorconfig: http://editorconfig.org/ .. _flake8: https://pypi.python.org/pypi/flake8 -- cgit v1.3