You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/04/07 15:40:47 UTC

[GitHub] [airflow] bbovenzi commented on a diff in pull request #22835: Remove extraneous json parsing in Calendar and Grid

bbovenzi commented on code in PR #22835:
URL: https://github.com/apache/airflow/pull/22835#discussion_r845286179


##########
airflow/www/static/js/calendar.js:
##########
@@ -63,9 +63,6 @@ const dateFormat = 'YYYY-MM-DD';
 document.addEventListener('DOMContentLoaded', () => {
   $('span.status_square').tooltip({ html: true });
 
-  // JSON.parse is faster for large payloads than an object literal
-  const rootData = JSON.parse(calendarData);

Review Comment:
   How so? It is already a json object at this point... Or should we just not use `htmlsafe_json_dumps()`?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org