sagemath / sagecell

The Sage Cell Server---providing a way to embed Sage computations into any web page.
Other
201 stars 70 forks source link

The classname of an embedded div cannot be sagecell #542

Open bnmnetp opened 3 years ago

bnmnetp commented 3 years ago

Maybe this is obvious to others, but I was beating my head against the wall trying to get embedded sagecell to work. I thought that 'sagecell' seemed like a nice descriptive name for my divs with sage cells in them. Except none of them would show up and there were no errors reported from the makeSageCell function. Finally I renamed them to 'compute' as in the example and then it worked. I finally figured out that any other class name would work EXCEPT sagecell.

Might be worth noting in the docs to save others the hassle.

rbeezer commented 2 years ago

@bnmnetp: You just saved me a whole lot of trouble. I wonder if there was a better choice than .sagecell for however it is being used, that would make it less likely for this to happen. Or perhaps at least an error message in the console. Or something. (And not require @siefkenj for reminding me of this one!) Thanks, Brad.