When trying out the new side bar feature, I realized that the build script is not triggered on running npm install.
I guess if there was an install script it would build to dist and then register the CLI binary in node_modules/.bin so that the following would work:
npm install purescript-docs-search
npm run purescript-docs-search