google / google/CodeCity

JSSP, SVG and String editors should accept single-quoted strings

Aperta
#449 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
/code
Lingua principale
JavaScript
Stelle
198
Fork
38
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

I made a modification to `$.utils.code.toSource` to use `$.utils.code.quote` instead of `JSON.stringify` to format strings (`.quote` prefers to use single quotes instead of double-quotes unless it would result in too many `\'`s), and in the process inadvertently broke the JSSP, SVG and String editors because they no longer comprehended the data to be edited.

Obviously I've reverted the change for now, and equally obviously it is a fool's errand to try to make the front ends fully general in what they can accept, but it would be nice for the editors to not be *quite* so dependent on the specifics of how the server chooses to represent the values to be edited.

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia individuando $.utils.code.toSource e gli editor JSSP, SVG e String che consumano il suo output. Traccia il modo in cui questi editor analizzano le stringhe tra virgolette, quindi verifica che accettino la rappresentazione tra apici singoli prodotta da $.utils.code.quote senza introdurre regressioni per l’input esistente tra virgolette doppie.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
javascript
Ambito
frontend
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.