IntelliSense in VSCode really slows when after add...
# azure
o
IntelliSense in VSCode really slows when after adding
@pulumi/azure-native
package in a typescript package. I checked, the package is huge, is there a way to only install the portions or types I need?
a
I've had the same problem with the Python SDK. This is what I did to make the situation there "bearable" – you might figure out equivelant TS settings. • I set the Python language server log level to trace
"python.analysis.logLevel": "Trace"
which is very verbose and looked at what was actually going on.. • Package indexing (
python.analysis.packageIndexDepths
) for
pulumi_azure_native
is set to 2 to make sure not all additional
vYYYYMMDD[-preview]
packages aren't indexed as the indexer will run out of memory • Make sure indices are persisted to disk
"python.analysis.persistAllIndices": true,
• Increase the index limit as the package contains so many objects
"python.analysis.userFileIndexingLimit": 25000,
• Be very careful when importing packages from as to wide imports can trigger VSCode indexer to go off the cliff ◦ No * imports ◦ Only from
pulumi_azure_native.<namespace> import <symbols>
◦ When importing versioned APIs ▪︎
from <http://pulumi_azure_native.app|pulumi_azure_native.app> import v20230801preview as app
▪︎ Not
import pulumi_azure_native.app.v20230801preview as app
as that will essentially import all parent namespaces