       #  }
       #  console.log code
       pirates?.settings = @settings
-      #@module = runWithMapping @, -> require filename
-      @module = require filename
+      #@exports = runWithMapping @, -> require filename
+      @exports = require filename
       @walkDeps filename
-      #console.log filename, @module
+      #console.log filename, @exports
     else
       ## But if file has been explicitly loaded (e.g. in browser),
       ## compile manually and simulate module.

      func = new Function \
        'exports', '__filename', '__dirname', 'svgtiler', 'preact', code
      #runWithMapping @, ->
      func @module, _filename, _dirname, svgtiler,
        (if code.includes 'preact' then require 'preact')
    if @settings.verbose
      console.log "# Module #{@filename} exported {#{Object.keys(@module).join ', '}}"
    super (@module.map ? @module.default), @constructor.optsFrom @module
  walkDeps: (filename) ->
    deps = new Set
    recurse = (modname) =>

        filename: @filename
      }
      #console.log code
      @exports = {}
      ## Mimick NodeJS module's __filename and __dirname variables
      ## [https://nodejs.org/api/modules.html#modules_the_module_scope]
      _filename = path.resolve @filename
