Short answer
No — the alcohol in vanilla extract is especially risky for small dogs. Even a teaspoon can cause alcohol poisoning in a tiny pet. Stick to a tiny drop of alcohol-free vanilla or fresh vanilla bean for flavoring. If your small dog licks extract, watch for wobbliness or vomiting and call your vet promptly.
Vanilla extract — Food safety facts
Feed with care · Dogs · full breakdown on the linked food page
Vanilla itself is fine, but extract is mostly alcohol. Use only a drop, or use vanilla bean.
The full verdict, portion guidance and serving notes are collected on the Vanilla extract food facts page.