aboutsummaryrefslogtreecommitdiffstats
path: root/src/qmlcompiler/doc/qtqmlcompiler-index.qdoc
diff options
context:
space:
mode:
authorAlexei Cazacov <[email protected]>2024-07-03 15:49:25 +0300
committerAlexei Cazacov <[email protected]>2024-07-25 07:35:37 +0300
commitf7f0a07a94ff3ab8334f484e86d6831085afabd2 (patch)
tree84d1401a9358a8b5f1fc00d47a94ec003be82c07 /src/qmlcompiler/doc/qtqmlcompiler-index.qdoc
parenta45857eb9cd299e29d5cb872917b827f2632a0d1 (diff)
Docs: Organize topics in the qtdeclarative/Qt Qml Compiler project
This commit organizes the articles, so they: - have a reasonable tree structure - can be navigated through the topic tree in the Qt Creator help viewer Task-number: QTBUG-126648 Change-Id: Iafd5d3d63c2cc775a825b93bbe0409d3df233c7b Reviewed-by: Topi Reiniƶ <[email protected]>
Diffstat (limited to 'src/qmlcompiler/doc/qtqmlcompiler-index.qdoc')
-rw-r--r--src/qmlcompiler/doc/qtqmlcompiler-index.qdoc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/qmlcompiler/doc/qtqmlcompiler-index.qdoc b/src/qmlcompiler/doc/qtqmlcompiler-index.qdoc
index 3de06d577e..24175ec3be 100644
--- a/src/qmlcompiler/doc/qtqmlcompiler-index.qdoc
+++ b/src/qmlcompiler/doc/qtqmlcompiler-index.qdoc
@@ -28,6 +28,7 @@
The Qt QML Compiler module offers the QQmlSA framework which provides tools
for static analysis of QML code. These tools can help ensure syntactic
validity and warn about QML anti-patterns.
+
Adding static analysis to a QML program is done by writing plugins. They
will run a collection of analysis passes over the elements and properties
of the QML code. The passes can be registered with a PassManager which
@@ -44,10 +45,12 @@
the pass over every element it encounters while traversing the children of
the root element. For each element, if \c shouldRun() evaluated on that
element returns \c true then \c run() is executed on it.
+
Passes on properties trigger on three different events, namely when the
property is bound, when it is read, and when it is written to. These can be
implemented by overriding the \c onBinding(), \c onRead() and \c onWrite()
functions respectively.
+
As the code grows, so does the number of elements and properties.
Performing the static analysis passes on all of them can become expensive.
That's why it is good to be granular when deciding which elements and