switch lib to constructor style