import { ServiceSchema } from 'moleculer' ; import ApiGateway = require ( 'moleculer-web' ) ; const ApiService = { name : 'api' , mixins : [ ApiGateway ] , settings : { port : process . env . PORT || 3000 , routes : [ { aliases : { } , cors : { credentials : true , methods : [ 'GET' , 'OPTIONS' , 'POST' ] , origin : [ '*' ] , } , path : '/api' , } , ] , assets : { folder : 'public' , } , } , } ; export = ApiService ;