changed to revealing interface pattern
added amd module support