GithubHelp home page GithubHelp logo

isabella232 / cordova-plugin-log Goto Github PK

View Code? Open in Web Editor NEW

This project forked from moderna/cordova-plugin-log

0.0 0.0 0.0 188 KB

This is a phonegap/cordova 3.3.x plugin that writes all cordova javascript logs into a file in a public folder (Android: sdCard, iOS: ~/Documents).

License: Other

Java 100.00%

cordova-plugin-log's Introduction

Log

This is a pdf creation plugin for Phonegap 3.3.0 / Cordova 3.3.1 supporting Android (>=2.3.3). It writes all cordova javascript logs into a file in a public folder (Android: mnt/sdcard/, iOS: ~/Documents).

There are no JavaScript Methods (it´s hacked directly into the cordova log flow, "Usage below").

Installation

You may use phonegap CLI as follows:

➜ phonegap local plugin add https://github.com/moderna/cordova-plugin-log.git
[phonegap] adding the plugin: https://github.com/moderna/cordova-plugin-log.git
[phonegap] successfully added the plugin

Usage

ATTENTION: There is some manual work to be done before you can use this plugin!

Android:

  1. In edit the following variables to your liking:
    private String logDir = ".at.modalog.cordova.plugin.log"; // prepending a dot "." makes the directory invisible
    private String logFileName = "CordovaChromeClient.log";
    private double logFileMaxSizeInKiloBytes = 512;
  1. Open your apps main.java file and add this import statement:
    import at.modalog.cordova.plugin.log.CordovaChromeClientLog;
  1. Update your main.java file:
    // deactivate the regular init
    // super.init();

    // modify init to use "CordovaChromeClientLog"
    CordovaWebView webView = this.makeWebView();
    super.init(webView, makeWebViewClient(webView), CordovaChromeClientLog.makeChromeClient(this, webView));
    // ...

iOS:

iOS is not yet supported.

cordova-plugin-log's People

Contributors

geo-ma 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.