It works the same way CSS does, so you can use anything, but specificity matters because it factors into how Atom determines the priority of keybindings.
I’m then not sure which command to give the keybinding.
Settings -> Keybindings, you can see all of the keys and their commands. Searching for
pageup indicates that its command is
Before we continue, hit up
Packages -> Keybinding Resolver -> Toggle. It will provide a visual to explain the rest.
The default selector to address text is
atom-text-editor, so if I want a keybinding to modify text but don’t care about where it is, it will look something like this:
If you try that right now, you’ll see that it doesn’t work. The Keybinding Resolver shows you why: the binding from Emmet is more specific. The fact is,
atom-text-editor is also used for things like the Find and Replace field. This command is specific to the text buffer, and the selector for that is
If you try it again like this, you’ll see that your binding finally takes precedence. Now it’s at the same level of specificity, and
keymap.cson gets read late into the cascade, so it has a chance to overrule any packages.