diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2019-03-01 10:42:06 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2019-03-04 10:08:03 +0000 |
commit | ce1680fb017ef141106f74afd318632a712547e1 (patch) | |
tree | acd0ea85032d5957e8c981afbbd8dd664495ec19 /src/qml/qml | |
parent | af055ca5793a4a3a3e306e8bc605665e6ae24bfd (diff) |
Doc: Promote use of ECMAScript modules over Qt.include()
Also, mention that Qt.include() is deprecated.
[ChangeLog][QtQml] Qt.include() is deprecated in favor of ECMAScript
modules.
Task-number: QTBUG-74068
Change-Id: Ia13e4f1577d86b869a9a1cd810a82ff0b27ea0cc
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/qml')
-rw-r--r-- | src/qml/qml/qqmlengine.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp index 5841a480fc..0a26ed89cc 100644 --- a/src/qml/qml/qqmlengine.cpp +++ b/src/qml/qml/qqmlengine.cpp @@ -661,6 +661,10 @@ The following functions are also on the Qt object. /*! \qmlmethod object Qt::include(string url, jsobject callback) +\deprecated + +This method should not be used. Use ECMAScript modules instead and the native +JavaScript \c import and \c export statements instead. Includes another JavaScript file. This method can only be used from within JavaScript files, and not regular QML files. |