Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

clogy

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

clogy - npm Package Compare versions

Comparing version 1.3.1 to 1.3.2

4

CHANGELOG.md
# clogy changelog
## 1.3.2
- Refactored index.d.ts
## 1.3.1

@@ -4,0 +8,0 @@

19

index.d.ts

@@ -6,3 +6,3 @@ // Type definitions for clogy

declare type ClogyOptionsType = {
type ClogyOptionsT = {
showDateTime?: boolean,

@@ -12,3 +12,3 @@ prefix?: string

declare type LevelsType = {
type ClogyLevelsT = {
log: number,

@@ -23,5 +23,5 @@ trace: number,

interface ILogger {
getOptions(): ClogyOptionsType;
setOptions(options: ClogyOptionsType): void;
interface IClogyLogger {
getOptions(): ClogyOptionsT;
setOptions(options: ClogyOptionsT): void;
getLevel(): number | null;

@@ -32,3 +32,3 @@ setLevel(level: number | string): void;

disableAllLevels(): void;
LEVELS: LevelsType;
LEVELS: ClogyLevelsT;
log(...args: Array<any>): void;

@@ -42,9 +42,8 @@ trace(...args: Array<any>): void;

interface IClogy extends ILogger {
new(): this;
noConflict(): this;
interface IClogyMain extends IClogyLogger {
noConflict(): IClogyMain;
decorator(decoFunc: () => void): void;
}
declare const clogy: IClogy;
declare const clogy: IClogyMain;

@@ -51,0 +50,0 @@ declare module 'clogy' {

@@ -1,2 +0,2 @@

/*! clogy - v1.3.1 * https://github.com/pgmanutd/clogy * (c) 2017 pgmanutd * licensed MIT */
/*! clogy - v1.3.2 * https://github.com/pgmanutd/clogy * (c) 2017 pgmanutd * licensed MIT */
(function webpackUniversalModuleDefinition(root, factory) {

@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object')

@@ -1,3 +0,3 @@

/*! clogy - v1.3.1 * https://github.com/pgmanutd/clogy * (c) 2017 pgmanutd * licensed MIT */
/*! clogy - v1.3.2 * https://github.com/pgmanutd/clogy * (c) 2017 pgmanutd * licensed MIT */
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.clogy=t():e.clogy=t()}(this,function(){return function(e){function t(o){if(n[o])return n[o].exports;var r=n[o]={exports:{},id:o,loaded:!1};return e[o].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){e.exports=n(7)},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.LOGGING_METHODS=t.LOGGING_LEVELS=t.LOGGING_DEFAULT_OPTIONS=void 0;var r=n(4),i=o(r),u=n(5),l=o(u),s=n(6),f=o(s);t.LOGGING_DEFAULT_OPTIONS=i.default,t.LOGGING_LEVELS=l.default,t.LOGGING_METHODS=f.default},function(e,t,n){"use strict";function o(){return"undefined"!=typeof console}function r(e){return!!(e&&e>=s.LOGGING_LEVELS.range.min&&e<=s.LOGGING_LEVELS.range.max)}function i(e){return e===s.LOGGING_LEVELS.types.none}function u(e,t){return s.LOGGING_LEVELS.types[t]>=e}function l(){var e=new Date,t=e.toDateString(),n=e.toTimeString().match(/^([0-9]{2}:[0-9]{2}:[0-9]{2})/),o=n&&n.length?n[0]:"",r=("00"+e.getMilliseconds()).slice(-3);return t+" "+o+"."+r}t.__esModule=!0;var s=n(1);t.default={isConsoleDefined:o,isLogLevelValid:r,isNoneLogLevel:i,isLoggingAllowed:u,getDateTime:l}},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.singleton=t.logging=t.common=void 0;var r=n(2),i=o(r),u=n(10),l=o(u),s=n(11),f=o(s);t.common=i.default,t.logging=l.default,t.singleton=f.default},function(e,t){"use strict";t.__esModule=!0,t.default=Object.freeze({showDateTime:!1,prefix:""})},function(e,t){"use strict";t.__esModule=!0,t.default=Object.freeze({get types(){return{log:1,trace:2,debug:3,info:4,warn:5,error:6,none:7}},get range(){return{min:this.types.log,max:this.types.none}}})},function(e,t){"use strict";t.__esModule=!0,t.default=["log","trace","debug","info","warn","error"]},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0;var r=n(8),i=o(r),u=new i.default;t.default=u,e.exports=u},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0;var l=n(3),s=n(9),f=o(s),c=function(e){function t(){return r(this,t),i(this,e.apply(this,arguments))}return u(t,e),t.prototype.noConflict=function(){return"undefined"!=typeof window&&window.clogy&&delete window.clogy,this},t.prototype.decorator=function(e){if("function"!=typeof e)throw new TypeError("Decorator should be a function");e(l.singleton.getInstance(this))},t}(f.default);t.default=c},function(e,t,n){"use strict";function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}t.__esModule=!0;var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),u=n(1),l=n(3),s=function(){function e(){o(this,e),this._options={showDateTime:null,prefix:null},this._level=null,this._setDefaults()}return e.prototype._setDefaults=function(){this.setOptions(u.LOGGING_DEFAULT_OPTIONS),this.setLevel(this.LEVELS.info)},e.prototype.getOptions=function(){return this._options},e.prototype.setOptions=function(e){this._options=r({},this.getOptions(),e)},e.prototype.getLevel=function(){return this._level},e.prototype.setLevel=function(e){this._level="string"==typeof e?this.LEVELS[e.toLowerCase()]:e},e.prototype.stringifyAllowedLoggers=function(){var e=this,t="✔",n="✖";return u.LOGGING_METHODS.map(function(o,r){return r+1+": "+o+" "+(l.common.isLoggingAllowed(e.getLevel(),o)?t:n)}).join("\n")},e.prototype.enableAllLevels=function(){this.setLevel(this.LEVELS.log)},e.prototype.disableAllLevels=function(){this.setLevel(this.LEVELS.none)},i(e,[{key:"LEVELS",get:function(){return u.LOGGING_LEVELS.types}}]),e}(),f=s.prototype;u.LOGGING_METHODS.forEach(function(e){f[e]=function(){for(var t={currentLogLevel:this.getLevel(),loggingType:e,options:this.getOptions()},n=arguments.length,o=Array(n),r=0;r<n;r++)o[r]=arguments[r];l.logging.logToConsole(t,o)}}),t.default=s},function(e,t,n){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}function r(e){var t=[];return e.showDateTime&&t.push(f.default.getDateTime()+": "),e.prefix&&t.push(e.prefix),t}function i(e,t){var n=console[e]||console[c];n&&Function.prototype.bind.call(n,console).apply(console,t)}function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.currentLogLevel,n=e.loggingType,o=e.options,u=void 0===o?l.LOGGING_DEFAULT_OPTIONS:o,s=arguments[1];if(f.default.isConsoleDefined()){if(!f.default.isLogLevelValid(t))throw new RangeError("Invalid LogLevel set, Please set a valid LogLevel");!f.default.isNoneLogLevel(t)&&f.default.isLoggingAllowed(t,n)&&i(n,[].concat(r(u),s))}}t.__esModule=!0;var l=n(1),s=n(2),f=o(s),c="log";t.default={logToConsole:u}},function(e,t){"use strict";function n(e){var t=Object.getPrototypeOf;return t(t(e))}function o(e){return r||(r=n(e)),r}t.__esModule=!0;var r=void 0;t.default={getInstance:o}}])});
//# sourceMappingURL=clogy.min.js.map
{
"name": "clogy",
"version": "1.3.1",
"version": "1.3.2",
"description": "A logging library for browsers and nodejs environment",

@@ -73,24 +73,24 @@ "homepage": "https://github.com/pgmanutd/clogy",

"devDependencies": {
"babel-eslint": "^7.1.1",
"babel-loader": "^6.2.10",
"babel-plugin-istanbul": "^3.1.2",
"babel-eslint": "^7.2.3",
"babel-loader": "^7.0.0",
"babel-plugin-istanbul": "^4.1.3",
"babel-plugin-transform-flow-strip-types": "^6.22.0",
"babel-plugin-transform-object-rest-spread": "^6.22.0",
"babel-polyfill": "^6.22.0",
"babel-preset-es2015": "^6.22.0",
"babel-register": "^6.22.0",
"babel-plugin-transform-object-rest-spread": "^6.23.0",
"babel-polyfill": "^6.23.0",
"babel-preset-es2015": "^6.24.1",
"babel-register": "^6.24.1",
"chai": "^3.5.0",
"coveralls": "^2.11.15",
"coveralls": "^2.13.1",
"del": "^2.2.2",
"eslint": "^3.14.1",
"eslint-plugin-flowtype": "^2.30.0",
"eslint": "^3.19.0",
"eslint-plugin-flowtype": "^2.32.1",
"eslint-plugin-lodash-fp": "^2.1.3",
"express": "^4.14.1",
"flow-bin": "^0.38.0",
"express": "^4.15.2",
"flow-bin": "^0.45.0",
"gulp": "^3.9.1",
"gulp-bump": "^2.6.1",
"gulp-bump": "^2.7.0",
"gulp-eslint": "^3.0.1",
"gulp-forever-monitor": "1.0.0",
"gulp-forever-monitor": "1.0.2",
"gulp-help": "^1.6.1",
"gulp-load-plugins": "^1.4.0",
"gulp-load-plugins": "^1.5.0",
"gulp-plumber": "^1.1.0",

@@ -100,3 +100,3 @@ "gulp-replace": "^0.5.4",

"html-webpack-plugin": "^2.28.0",
"karma": "^1.4.0",
"karma": "^1.6.0",
"karma-babel-preprocessor": "^6.0.1",

@@ -106,13 +106,13 @@ "karma-chai": "^0.1.0",

"karma-coverage": "^1.1.1",
"karma-firefox-launcher": "^1.0.0",
"karma-firefox-launcher": "^1.0.1",
"karma-ie-launcher": "^1.0.0",
"karma-mocha": "^1.3.0",
"karma-phantomjs-launcher": "^1.0.2",
"karma-phantomjs-launcher": "^1.0.4",
"karma-sinon": "^1.0.5",
"karma-sinon-chai": "^1.2.4",
"karma-sinon-chai": "^1.3.1",
"karma-sourcemap-loader": "^0.3.7",
"karma-spec-reporter": "0.0.26",
"karma-webpack": "^2.0.2",
"karma-spec-reporter": "0.0.31",
"karma-webpack": "^2.0.3",
"lodash": "^4.17.4",
"mocha": "^3.2.0",
"mocha": "^3.3.0",
"path": "^0.12.7",

@@ -123,9 +123,9 @@ "phantomjs-prebuilt": "^2.1.14",

"run-sequence": "^1.2.2",
"sinon": "^1.17.7",
"sinon-chai": "^2.8.0",
"sinon": "^2.1.0",
"sinon-chai": "^2.9.0",
"webpack": "^1.14.0",
"webpack-dev-middleware": "^1.9.0",
"webpack-hot-middleware": "^2.15.0",
"yargs": "^6.6.0"
"webpack-dev-middleware": "^1.10.2",
"webpack-hot-middleware": "^2.18.0",
"yargs": "^7.1.0"
}
}

@@ -47,15 +47,15 @@ # clogy [![npm](https://img.shields.io/npm/v/clogy.svg)](https://www.npmjs.com/package/clogy) [![Build Status](https://travis-ci.org/pgmanutd/clogy.svg?branch=master)](https://travis-ci.org/pgmanutd/clogy) [![Coverage Status](https://coveralls.io/repos/github/pgmanutd/clogy/badge.svg?branch=master)](https://coveralls.io/github/pgmanutd/clogy?branch=master)

**rawgit**: ```//rawgit.com/pgmanutd/clogy/1.3.1/lib/clogy.js```
**rawgit**: ```//rawgit.com/pgmanutd/clogy/1.3.2/lib/clogy.js```
or
**unpkg**: ```//unpkg.com/clogy@1.3.1/lib/clogy.js```
**unpkg**: ```//unpkg.com/clogy@1.3.2/lib/clogy.js```
* ```Production```:
**rawgit**: ```//cdn.rawgit.com/pgmanutd/clogy/1.3.1/lib/clogy.min.js```
**rawgit**: ```//cdn.rawgit.com/pgmanutd/clogy/1.3.2/lib/clogy.min.js```
or
**unpkg**: ```//unpkg.com/clogy@1.3.1/lib/clogy.min.js```
**unpkg**: ```//unpkg.com/clogy@1.3.2/lib/clogy.min.js```

@@ -62,0 +62,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc