GithubHelp home page GithubHelp logo

ikasumiwt / screenlog.js Goto Github PK

View Code? Open in Web Editor NEW

This project forked from chinchang/screenlog.js

0.0 2.0 0.0 62 KB

Bring console.log on the screen

License: MIT License

JavaScript 92.67% HTML 7.33%

screenlog.js's Introduction

screenlog.js npm version

Bring console.log, on the screen


Ever faced a situation where you said "Why doesn't this bug show up when developer console is open!!"? And since the bug doesn't show when you have console open, you cannot do debug logging using console.log.

Enter screenlog.js. screenlog.js brings the developer console right on your screen so that you can do logging without having the developer console open always.

Screenshot

Usage

Do npm install screenlog or bower install screenlog or download the project.

Drop dist/screenlog.min.js into your web application and initialize it with:

screenLog.init();

And you are done! By default, every next console.log in your app now starts logging on the screen as well as the console. Or you can use screenLog.log() instead to just log on the screen.

Public API

screenLog.init([options])

Initializes the screen logger. It creates a customizable panel on the screen.

  • options - A map of additional options.
    • color - Text color. Default is lightgreen.
    • bgColor - Background color of the log panel. Default is black.
    • releaseConsole - By default console.log is overridden to log on screen. You can avoid this behaviour by setting releaseConsole to true and instead use screenLog.log() API. Default is false.

screenLog.log(obj1 [, obj2, ..., objN])

Logs a message on the screen.

  • obj1 ... objN - A list of JavaScript objects or strings to output. Just like console.log.

screenLog.clear()

Clears messages on the screen.

screenLog.destroy()

Removes the logger from the UI and reverts to original console functionality.

Browser Support

screenlog.js works best on latest versions of Google Chrome, Firefox and Safari.

Contributing

Interested in contributing features and fixes?

Read more on contributing.

Changelog

See the Changelog

License

Copyright (c) 2015-2016 Kushagra Gour, http://kushagragour.in Licensed under the MIT license.

screenlog.js's People

Contributors

chinchang avatar gnithin avatar prayagverma avatar vivekannan avatar

Watchers

James Cloos avatar yusuke Kato avatar

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.