Merge pull request #1 from aaronfrost/incremental-instrumentation-stale

docs: add inline documentation
test-unit-sauce
Brian Ford 10 years ago
commit 8e7ae1e968

2
.gitignore vendored

@ -1,2 +1,4 @@
batarang-release-*.zip
*.build.js
.idea
node_modules

@ -38,11 +38,11 @@ module.exports = function(grunt) {
zip: {
release: {
src: [
'css/*.css',
'img/**',
'js/**',
'panes/*.html',
'panel.html',
'devtools-panel/css/*.css',
'devtools-panel/img/**',
'devtools-panel/js/**',
'devtools-panel/panes/*.html',
'devtools-panel/panel.html',
'LICENSE',
'manifest.json',
'background.html',

@ -1,7 +1,15 @@
/**
* This code loads the UI for the DevTools.
*
* HOW DOES THIS CODE GET LOADED INTO THE EXTENSION?
* In the 'manifest.json', the 'devtools_page' options
* loads 'devtoolsBackground.html' which links this file.
*
*/
var panels = chrome.devtools.panels;
// The function below is executed in the context of the inspected page.
var getPanelContents = function () {
if (window.angular && $0) {
//TODO: can we move this scope export into updateElementProperties
@ -29,6 +37,7 @@ var getPanelContents = function () {
}
};
// This adds the AngularJS Propeties piece to the Elements tab in devtools.
panels.elements.createSidebarPane(
"AngularJS Properties",
function (sidebar) {
@ -37,7 +46,7 @@ panels.elements.createSidebarPane(
});
});
// Angular panel
// This adds the tab that appears at the top of your devtools, just after the console.
var angularPanel = panels.create(
"AngularJS",
"devtools-panel/img/angular.png",

@ -1,5 +1,10 @@
// Similar to browserify, but inlines the scripts instead.
// This is a really dumb naive approach that only supports `module.exports =`
/**
* This file takes all of the files in 'content-scripts/' and concats
* then into one file. This so that only one file will need to be
* injected into the content of a page.
*
* You will need to run 'grunt inline' to build the new 'inject.build.js'
*/
var fs = require('fs');
var r = new RegExp("( *)(.*?)require\\('(.+?)'\\)", 'g');