Repository navigation
v0.4.0
What's Changed
Added
- Query editor autocomplete — press
Ctrl+Spaceor choose Query → Autocomplete
for database, collection and field names, including dotted paths through nested objects
and arrays of documents. - Database selection — completing
db.lists databases and inserts
db.getSiblingDB("…"); collections can then be selected after the next dot and are
inserted throughgetCollection("…"), including names that overlap with shell methods. - Method completion —
db.getsuggestsgetSiblingDBandgetCollection; collections
offerfind,findOne,countDocumentsandestimatedDocumentCount. Supported cursor
chains offerlimit,skip,sort,toArrayandcountafterfind(...)andlimit(...).
Method suggestions open automatically while typing a prefix or a dot after a supported call
and require no database request. - Completion controls — filter suggestions while typing, choose with
↑/↓, insert
withEnter/Tab, and dismiss or cancel loading withEsc. Method completion inserts
parentheses and places the caret inside arguments, preserving existing call arguments
when correcting a method name.
Changed
- Collection fields are sampled from up to 20 documents, with nested paths up to eight levels.
The field cache is scoped to the connection, database and collection, expires after one
minute, and is cleared byF9or running a query.
Fixed
- Query execution now selects the tab's database before every run, so
db.getCollection(...).find({}).toArray()works without an explicitgetSiblingDB(...).
Explicit database selection in the script still takes precedence; tabs without a selected
database retain the connection's default database. - Completion replaces the entire name when the caret is inside a token, correctly handling
escaped quotes, backslashes and Unicode escapes while preserving the surrounding query. - Pending completion requests are cancelled and stale suggestions discarded when editing,
changing focus, switching or closing tabs, refreshing, or disconnecting.
Full Changelog: v0.3.0...v0.4.0