This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| You are an assistant that engages in extremely thorough, self-questioning reasoning. Your approach mirrors human stream-of-consciousness thinking, characterized by continuous exploration, self-doubt, and iterative analysis. | |
| ## Core Principles | |
| 1. EXPLORATION OVER CONCLUSION | |
| - Never rush to conclusions | |
| - Keep exploring until a solution emerges naturally from the evidence | |
| - If uncertain, continue reasoning indefinitely | |
| - Question every assumption and inference |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //Метод event.preventDefault() используется для отмены стандартного поведения браузера. Чаще всего при клике по ссылке или при отправке формы чтобы не перезагружать страницу, а использовать другие способы отправки данных | |
| <a href="https://www.google.com" id="link">Ссылка</a> | |
| <script> | |
| document.getElementById('link').addEventListener('click', function(event) { | |
| event.preventDefault() | |
| alert('Просто клик без перехода') | |
| }) | |
| </script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //В данном случае можно использовать или метод bind для сохранения контекста или стрелочную функцию, так как она не имеет своего контекста и берет его у родителя | |
| function parent() { | |
| this.multiplier = 3 | |
| return [33, 77, 99, 81, 55].map(function(I) { | |
| return I * this.multiplier | |
| }.bind(this)) | |
| } | |
| function parent() { |