timpla
Version:
An optimal website development experience for [server-side] web frameworks.
52 lines (44 loc) • 1.33 kB
JavaScript
// @ts-check
/**
* The @type annotations are harmless, vscode might just make your life easier
* by adding intellisense support whilst you type!
*/
const { configure } = require('./lib/public')
module.exports = configure({
javascripts: {
useTypeScript: false,
/** @type { import("./lib/public").ITimplaWebpackEntryHook } */
entry: ({ resolve: r }) => ({
'js-index': r('./js-index.jsx'),
}),
/** @type { import("./lib/public").ITimplaCustomizeWebpackConfig } */
customizeWebpackConfig(w) {
// The following helpers are available to aid you in extending the webpack config.
const {
projectDestPath,
projectSrcPath,
timplaConfig,
timplaProcess,
webpack,
webpackConfig,
webpackMerge,
} = w
return w.webpackConfig
},
},
// To get intellisense for more complex configs, follow the jsdoc example below:
// html: {
// /** @type { import("./lib/public").ITimplaHofTask } */
// alternate: p => {
// p.timplaProcess
// },
// },
// additionalTasks: {
// /** @param p { import("./lib/public").ITimplaHelper } */
// initialize: p => {},
// development: {
// /** @type { import("./lib/public").ITimplaHofTask } */
// prebuild(tp) {},
// },
// },
})