Choose the whole pair
The technique
ca( would replace the brackets as well. Start inside the pair you mean.
Keys in this lesson
- ci(
- Change the text inside round brackets.
- ca(
- Change the brackets and what they hold.
- ci[
- Change inside square brackets.
- ci{
- Change inside curly brackets.
- ci'
- Change inside single quotes.
Before this lesson: Words and quotations.
More about this lesson
Change what's inside a pair of brackets or quotes, or the pair as well. Start inside the one you mean.
i keeps the pair around the text and a takes the pair too. So ci( changes the arguments and ca( replaces the brackets as well. A bracket pair can span several lines, and inside nested brackets you get the innermost pair. If you start before a call, Vim 9.1 and this editor use the next pair on the line, but older versions of Vim do nothing, so start inside the pair you mean. Quote objects stay inside the quotation you're in.
Example
From inside (draft), ci( then ready then Esc gives (ready). ca( then ready gives just ready, without the brackets.
Use Start over to try again.
Guides on this topic
Exercise 1 of 6
0keys
par 9track takes one event object now. Pass it just the event built on the line above.
Make it look like this
import { track } from "./track"; import { addToCartEvent } from "./events"; // Sent when a product goes into the cart. The dashboard counts these per product. export function trackAddToCart(product, quantity) { const event = addToCartEvent(product, quantity); track(event); }