Skip to content

Using DOM.js library kills console.log #7610

Open
@jht9629-nyu

Description

@jht9629-nyu

Most appropriate sub-area of p5.js?

  • Accessibility
  • Color
  • Core/Environment/Rendering
  • Data
  • DOM
  • Events
  • Image
  • IO
  • Math
  • Typography
  • Utilities
  • WebGL
  • Build process
  • Unit testing
  • Internationalization
  • Friendly errors
  • Other (specify if possible)

p5.js version

p5.js/1.11.1

Web browser and version

133.0.6943.127 (Official Build) (arm64)

Operating system

macosx

Steps to reproduce this

Steps:

  1. open https://editor.p5js.org/jht9629-nyu/sketches/VY-KQxJkA
  2. run
  3. error appears in console:
  4. "RangeError: Maximum call stack size exceeded"
  5. comment out DOM.js include in index.html
  6. run script and console now shows expected messages

-Also logged as issue on DOM.js:

Snippet:

// https://editor.p5js.org/jht9629-nyu/sketches/VY-KQxJkA
// DOM.js console.log bug
// run this sketch and get error:
//   "RangeError: Maximum call stack size exceeded"
// disable DOM.js include and console.log works
//
function setup() {
 console.log('in setup');
}

function draw() {
 console.log('in draw'); 
}

console.log('pre setup');

index.html scripts

    <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/1.11.1/p5.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/1.11.1/addons/p5.sound.min.js"></script>
    <script src="https://cdn.jsdelivr.net/gh/lenincompres/DOM.js@latest/DOM.js"></script>

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions