Comments (7)
Because sometimes it's used without electron (with NW.js for example).
from electron-log.
Let's just check electron/electron#2288 (comment) ;)?
from electron-log.
Thanks for the information, I forgot about that. But there is one problem - how to require electron and don't break a non-electron project which uses webpack.
from electron-log.
require
only after check that it is electron. require
is not restricted to be only on top file level. For ES6 as well (as yarn or electron-builder uses https://github.com/zertosh/babel-plugin-transform-inline-imports-commonjs).
from electron-log.
I thinked before that webpack/babel doesn't care whether require is called on a top level or not. Thanks for the idea, I'll check it later.
from electron-log.
Thank you for amazing module without tons of questionable dependencies :) This module will be recommended by electron-builder to debug auto-updater.
from electron-log.
Now it uses app.getName
from electron-log.
Related Issues (20)
- Unhandled electron-log error TypeError: The "path" argument must be of type string. Received undefined
- Issues with electron vite and v5 building HOT 1
- On Windows (no bug on Mac) sometimes see JavaScript error when app starts using log. HOT 2
- Add docs for File type
- Logging from renderer to file does not work with custom resolvePathFn HOT 5
- How to Custom the maxFileSzie of log HOT 3
- when i use function addLevel, it indeed work but TypyScript reports type error HOT 1
- Message duplicated in dev console HOT 1
- Error: Attempted to register a second handler for '__ELECTRON_LOG__' HOT 3
- In dev mode, logs can be saved to a file, but in production mode, logs cannot be saved to a file HOT 1
- How to output renderer log to custom filePath
- Environment variable for log.transports.console.level? HOT 3
- Error when calling readAllLogs
- 5.1.4 (and 5.1.3) missing from NPM HOT 1
- log.transport.file not accessible in Angular app HOT 1
- Can not log when `undefined` return by getAppName() HOT 2
- [possible malware alert] forked package `log-electron` contains a possibly-malicious payload loader. HOT 1
- Packaged log output
- Got a error "data.map is not a function" when I custom a transport.file.format. HOT 1
- logRender cannot write log to file. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from electron-log.