Answer the question
In order to leave comments, you need to log in
How to properly edit scripts built into Bitrix JS?
I placed the component on the page, copied the built-in template to fix it, and ran into a problem:
I need to change the block width, but it is calculated in the component script /bitrix/components/bitrix/search.title/script.js
If I change it, then on a subsequent update, it may change and my template will break.
In other components, this script usually lies in the template.
What is the right thing to do in this case?
Copy this file to the template and include it in the template? And how then to disable the built-in script?
Answer the question
In order to leave comments, you need to log in
as an option:
copy the component to /local/components/,
rename it
, edit it as you need
and call it in the right place
in this option, it will be like your own component based on the standard one, and it will not crash when updated.
Copy this file to the template and include it in the template? And how then to disable the built-in script?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question