updated for npm use