Giter Site home page Giter Site logo

alecperkins / coffeetable Goto Github PK

View Code? Open in Web Editor NEW
106.0 106.0 6.0 584 KB

A drop-in workbench for experimentation, CoffeeTable is a CoffeeScript-fluent browser console.

Home Page: http://alecperkins.net/coffeetable/

License: The Unlicense

CoffeeScript 97.86% JavaScript 2.14%

coffeetable's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

coffeetable's Issues

Autosuggest matching pollutes the built-in console

After typing a (, the autosuggest regex starts throwing lots of 'SyntaxError: Invalid regular expression'. It doesn't break anything, but the console gets flooded with the errors as the user types. CoffeeTable should catch and suppress these errors.

API: .log, .dir, and .execute methods

Similar to console.log and console.dir, be able to programmatically log to the CoffeeTable history.

  • log - print out the specified string (or .toString output)
  • dir - print out an expandable list of the specified object's properties and prototype
  • execute - compile and evaluate the specified CoffeeScript source

.dir depends on #4 and #6

Enumerate prototype

Show methods inherited through the prototype chain, and visually indicate how many levels.

Better instructions for how to use the widget

The instruction on how to submit code in multi-line mode are only displayed when there are no items in history. Instead, the instructions should be displayed when no history, and additionally whenever the mode is toggled.

Styles should be done using proper CSS

Styles are applied using $.css (to avoid conflicts, which it does unsuccessfully). Instead, the widget should get a unique ID, and have a <style> block with a reset and the necessary styles appended to <head>.

Autocomplete of global variables and their properties

As the user types, show global variables that match what the user has typed so far. When the user hits '.', start drilling down into the properties of the object. When the user presses 'tab', auto complete using the top suggestion.

Basically how the Chrome console does it, but with an actual list of suggestions.

Calls to .log and .dir can come in before widget fully ready

Currently, calling CoffeeTable.log, etc, before the widget has finished loading results in an error since the widget's DOM isn't complete. DOM ready isn't reliable, since the widget is already initializing after DOM ready by default. Calls to the API need to be buffered if the widget hasn't finished initializing. Or perhaps a 'ready' event on the widget that can handle a callback.

Import/Export history

Import and export input history from and to a file.

(And perhaps to GitHub gists. This needs some research.)

Pure JS build process

Instead of Sass, use Stylus for the style compilation process, and Uglify instead of Closure Compiler for the minified version. This way, the entire process is pure JavaScript.

Library-free

Eliminate the need for jQuery as a dependency, but allow it (and perhaps Underscore?) to be easily loaded with a single click.

clearing localstorage option, or no auto-replay

I entered document.write("hello") which overwrote the page. But since it automatically stores the code and replays it, the page was no longer visible. Until I manually deleted the row from localstorage using chrome's javascript console.
Perhaps just load the last typed line in the textbox without actually executing it.

Add 'replay' button

Allow users to replay the history on demand. Useful if it depends on stuff in the page that didn't happen prior to CoffeeTable loading.

Expand objects when displayed in the history

Right now the objects are listed simply as [object Object], which is kind of useless. The user should be able to click on the object and have its properties enumerated.

See the Chrome console for an example.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.