xcode-select --install
- Download the Space Gray colour theme
xcode-select --install
var el = document.createElement('script'); | |
el.src = "https://raw.githubusercontent.com/lodash/lodash/3.10.1/lodash.min.js"; | |
el.type = "text/javascript"; | |
document.head.appendChild(el) |
var chrome = {}; | |
chrome.devtools = {}; | |
chrome.declarativeWebRequest = {}; | |
//#region Types | |
//#region Chrome.AccessibilityObject | |
chrome.AccessibilityObject = function () { | |
/// <field name='type' type='string'>The type of this object, which determines the contents of 'details'.</field> | |
/// <field name='name' type='string'>The localized name of the object, like OK or Password. Do not rely on an exact string match because the text will be in the user's language and may change in the future.</field> | |
/// <field name='context' type='string'>The localized name of the context for the object, like the name of the surrounding toolbar or group of controls.</field> | |
/// <field name='details' type=''>Other details like the state, depending on the type of object.</field> |
The idea is based on a gist by @jimbojsb.
You can use Pygments or Highlight.
brew install python
Step 1: Create Movie Add form | |
• movies.html | |
<form action="/movies/" method="post"> {% csrf_token %} | |
Movie Name: <input type="Text" name="name"> <input type="submit" value="Add"> | |
</form> | |
• views.py |
var chrome = {}; | |
chrome.devtools = {}; | |
chrome.declarativeWebRequest = {}; | |
//#region Types | |
//#region Chrome.AccessibilityObject | |
chrome.AccessibilityObject = function () { | |
/// <field name='type' type='string'>The type of this object, which determines the contents of 'details'.</field> | |
/// <field name='name' type='string'>The localized name of the object, like OK or Password. Do not rely on an exact string match because the text will be in the user's language and may change in the future.</field> | |
/// <field name='context' type='string'>The localized name of the context for the object, like the name of the surrounding toolbar or group of controls.</field> | |
/// <field name='details' type=''>Other details like the state, depending on the type of object.</field> |
// this is the background code... | |
// listen for our browerAction to be clicked | |
chrome.browserAction.onClicked.addListener(function (tab) { | |
// for the current tab, inject the "inject.js" file & execute it | |
chrome.tabs.executeScript(tab.ib, { | |
file: 'inject.js' | |
}); | |
}); |
<!doctype html> | |
<html> | |
<head> | |
<!-- Priority tags. These must come first. --> | |
<meta charset="utf-8"> | |
<meta http-equiv="x-ua-compatible" content="ie=edge; chrome=1"> <!-- Render Chrome if available or using latest version of Internet Explorer (Recommended). --> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"> | |
<!-- Document Title --> | |
<title>Page Title</title> | |
<!-- Allows control over where resources are loaded from. Place as early in the document as possible, only applies to content below this tag. --> |