config.js 490 B

1234567891011121314151617181920212223
  1. var dpr = 1; // If in browser environment
  2. if (typeof window !== 'undefined') {
  3. dpr = Math.max(window.devicePixelRatio || 1, 1);
  4. }
  5. /**
  6. * config默认配置项
  7. * @exports zrender/config
  8. * @author Kener (@Kener-林峰, kener.linfeng@gmail.com)
  9. */
  10. /**
  11. * Debug log mode:
  12. * 0: Do nothing, for release.
  13. * 1: console.error, for debug.
  14. */
  15. var debugMode = 0; // retina 屏幕优化
  16. var devicePixelRatio = dpr;
  17. exports.debugMode = debugMode;
  18. exports.devicePixelRatio = devicePixelRatio;