You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* if ( CKEDITOR.isDebug ) {
* if ( doSomeSuperUnnecessaryDebugChecks() ) {
* throw new CKEditorError( 'sth-broke: Kaboom!' );
* }
* }
The builder should have an option (enabled by default) to set that property to false and also to remove unreachable code. The Uglify.js has a --define option which allows to preset some variable and then remove code that will not be reachable, but I'm not sure if it's going to work with an object property. If this will be a problem, then we can:
Rename CKEDITOR.isDebug to CKEDITOR_DEBUG, but that would be ugly, as we also have CKEDITOR.isDev which could also be covered by a similar mechanism.
Add our own extension to Uglify.js which will check this.
The text was updated successfully, but these errors were encountered:
We removed CKEDITOR.isDebug so far. Thanks to the transpilation step we can introduce some DEBUG global now, but so far we haven't used the previous property, so let's do this once it's needed.
In https://github.com/ckeditor/ckeditor5-core/issues/38 we proposed couple of logging mechanisms, one of them being the
CKEDITOR.isDebug
property which can be used to wrap debug code.The builder should have an option (enabled by default) to set that property to
false
and also to remove unreachable code. The Uglify.js has a--define
option which allows to preset some variable and then remove code that will not be reachable, but I'm not sure if it's going to work with an object property. If this will be a problem, then we can:CKEDITOR.isDebug
toCKEDITOR_DEBUG
, but that would be ugly, as we also haveCKEDITOR.isDev
which could also be covered by a similar mechanism.The text was updated successfully, but these errors were encountered: