Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If named cell contains dash, cell embeds are blank #403

Closed
amyzhaoyu opened this issue Apr 13, 2022 · 1 comment
Closed

If named cell contains dash, cell embeds are blank #403

amyzhaoyu opened this issue Apr 13, 2022 · 1 comment
Labels
Bug Something isn't working Notebook

Comments

@amyzhaoyu
Copy link

Describe the bug

If I name a cell with a label containing a dash (eg. copy-top) - I can save it in the notebook, however, when I go to embed the notebook cells, the resulting embed (iframe, etc) is blank.

To Reproduce
Steps to reproduce the behavior:

  1. In a notebook, name a cell with a label containing a dash - (I didn't try other punctuation but assuming that is probably problematic as well).

image

  1. Click the checkmark.
  2. Go to ... --> export --> embed cells.

image

Expected behavior
Embed should work as expected (ie. the code/visualizations should render).

Desktop (please complete the following information):

  • OS: macOS Catalina
  • Browser: Chrome
@CobusT CobusT added Bug Something isn't working Embed/ Export labels Apr 16, 2022
@CobusT
Copy link
Collaborator

CobusT commented Apr 17, 2022

JavaScript does not allow dashes in variable names. In fact, when you create a JavaScript cell in a notebook such as:
copy-top = 10
you would get a syntax error.

We should validate the cell name field to avoid this from happening.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working Notebook
Projects
None yet
Development

No branches or pull requests

2 participants