You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TS can now suggestion properties that require bracket accessors, such as properties with whitespace or 🦄 in their names. Accepting once of these properties should automatically inserts a bracketed property accessor
Testing
In a js project
Create an object that has keys that are not normal JS identifiers
constz={'sp ace': 1}
Trigger suggestions by typing z.
✅ You see sp ace listed as a suggestion
Accept this suggestions
✅ Bracket property accessor is inserted: z['sp ace']
Other things to try
Try coming up with other property names that contain fun unicode characters
Try this for methods method names
The text was updated successfully, but these errors were encountered:
#36429
Complexity: 1
OS:
Summary
TS can now suggestion properties that require bracket accessors, such as properties with whitespace or 🦄 in their names. Accepting once of these properties should automatically inserts a bracketed property accessor
Testing
In a js project
Create an object that has keys that are not normal JS identifiers
Trigger suggestions by typing
z.
sp ace
listed as a suggestionAccept this suggestions
z['sp ace']
Other things to try
Try coming up with other property names that contain fun unicode characters
Try this for methods method names
The text was updated successfully, but these errors were encountered: