Repository URL to install this package:
|
Version:
4.0.2 ▾
|
/**
* @fileoverview This is a custom Jest transformer turning file imports into filenames.
* @see http://facebook.github.io/jest/docs/tutorial-webpack.html
*/
import { basename } from 'path'
/**
* @todo we can probably use this to uglify stuff
*/
const fileTransform = {
process(src: string, filename: string) {
return `module.exports = ${JSON.stringify(basename(filename))};`
},
}
export { fileTransform }
export default fileTransform
// export = fileTransform