renamed to standalonify, moved standalonification into its own function