implement nice require()