Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

141
Views
¿Cómo eliminar los marcadores si los datos son correctos en la validación en monocoeditor?

¿Agregué los marcadores de error usando setModelMarkers cuando tenía dtaa no válidos en la validación del contenido de un contenido yaml que se muestra en monocoeditor? Pero, ¿cómo eliminar esas marcas de error si tenemos datos válidos en el editor?

 monaco.editor.onDidCreateModel(function(model) { function validate() { var textToValidate = model.getValue(); // return a list of markers indicating errors to display // replace the below with your actual validation code which will build // the proper list of markers var markers = [{ severity: monaco.MarkerSeverity.Error, startLineNumber: 1, startColumn: 2, endLineNumber: 1, endColumn: 5, message: 'hi there' }]; // change mySpecialLanguage to whatever your language id is monaco.editor.setModelMarkers(model, 'mySpecialLanguage', markers); } var handle = null; model.onDidChangeContent(() => { // debounce clearTimeout(handle); handle = setTimeout(() => validate(), 500); }); validate(); }); // -- below this is the original canned example code: // Register a new language

Tomada la referencia de aquí. Validación de sintaxis de un idioma personalizado en el editor de Mónaco ¿Alguien puede ayudar?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!