mirror of
https://github.com/swc-project/swc.git
synced 2024-12-21 04:32:01 +03:00
24 lines
445 B
TypeScript
24 lines
445 B
TypeScript
// @allowJs: true
|
|
// @checkJs: true
|
|
// @noEmit: true
|
|
|
|
// @Filename: mod.js
|
|
// Based on a pattern from adonis
|
|
exports.formatters = {}
|
|
// @Filename: first.js
|
|
exports = require('./mod')
|
|
exports.formatters.j = function (v) {
|
|
return v
|
|
}
|
|
// @Filename: second.js
|
|
exports = require('./mod')
|
|
exports.formatters.o = function (v) {
|
|
return v
|
|
}
|
|
|
|
// @Filename: use.js
|
|
import * as debug from './mod'
|
|
|
|
debug.formatters.j
|
|
var one = debug.formatters.o(1)
|