owebjs 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-JSRKSHP6.js +1 -0
- package/dist/index.js +1 -1
- package/dist/utils/assignRoutes.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-HOV6IKC4.js +0 -1
- package/tsup.config.ts +0 -16
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as h}from"./chunk-OR3GJT5E.js";import{d as u,e as m}from"./chunk-XR5MHIBF.js";import{a as i}from"./chunk-2HA4XQFN.js";import c from"node:path";import{dirname as p}from"node:path";import{fileURLToPath as d}from"node:url";var g=p(d(import.meta.url)),w=i(async r=>{let n=[];for(let t of r){let s=c.parse(t.rel),e=t.filePath.replaceAll("\\","/"),a=new URL(c.resolve(e),`file://${g}`).pathname.replaceAll("\\","/"),l=u(s),o=m(l),f=await import(a);n.push({url:o.url,method:o.method,fn:f?.default,fileInfo:t})}return n},"generateRoutes"),U=i(async(r,n)=>{let t=await h(r),s=await w(t);for(let e of s)n[e.method](e.url,function(a,l){if(e.fileInfo.hooks.length)for(let o=0;o<e.fileInfo.hooks.length;o++){let f=e.fileInfo.hooks[o];new f().handle(a,l,()=>{o+1==e.fileInfo.hooks.length&&new e.fn(...arguments).handle(...arguments)})}else new e.fn(...arguments).handle(...arguments)})},"assignRoutes");export{w as a,U as b};
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as o}from"./chunk-
|
|
1
|
+
import{b as o}from"./chunk-JSRKSHP6.js";import"./chunk-OR3GJT5E.js";import"./chunk-XR5MHIBF.js";import{a as s}from"./chunk-2HA4XQFN.js";import n from"fastify";var a=n(),c=class{static{s(this,"FastifyInstance")}constructor(){Object.assign(this,a)}},t=class extends c{static{s(this,"Oweb")}constructor(){super()}loadRoutes({routeDir:e}){return o(e,a)}};export{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../chunk-
|
|
1
|
+
import{a,b}from"../chunk-JSRKSHP6.js";import"../chunk-OR3GJT5E.js";import"../chunk-XR5MHIBF.js";import"../chunk-2HA4XQFN.js";export{b as assignRoutes,a as generateRoutes};
|
package/package.json
CHANGED
package/dist/chunk-HOV6IKC4.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as c}from"./chunk-OR3GJT5E.js";import{d as h,e as u}from"./chunk-XR5MHIBF.js";import{a as i}from"./chunk-2HA4XQFN.js";import m from"node:path";import{dirname as p}from"node:path";import{fileURLToPath as d}from"node:url";var g=p(d(import.meta.url)),w=i(async r=>{let n=[];for(let t of r){let l=m.parse(t.rel),o=t.filePath.replaceAll("\\","/"),s=new URL(m.resolve(o),`file://${g}`).pathname.replaceAll("\\","/"),a=h(l),e=u(a),f=await import(s);n.push({url:e.url,method:e.method,fn:f?.default,fileInfo:t})}return n},"generateRoutes"),U=i(async(r,n)=>{let t=await c(r),l=await w(t);for(let o of l)n[o.method](o.url,function(s,a){if(o.fileInfo.hooks.length)for(let e=0;e<o.fileInfo.hooks.length;e++){let f=o.fileInfo.hooks[e];new f().handle(s,a,()=>{e+1==o.fileInfo.hooks.length&&new o.fn().handle(...arguments)})}else new o.fn().handle(...arguments)})},"assignRoutes");export{w as a,U as b};
|
package/tsup.config.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from 'tsup';
|
|
2
|
-
|
|
3
|
-
export default defineConfig({
|
|
4
|
-
target: "esnext",
|
|
5
|
-
dts: {
|
|
6
|
-
resolve: true,
|
|
7
|
-
entry: './src/index.ts',
|
|
8
|
-
},
|
|
9
|
-
keepNames: true,
|
|
10
|
-
entryPoints: ['./src/**/*.ts'],
|
|
11
|
-
clean: true,
|
|
12
|
-
format: 'esm',
|
|
13
|
-
splitting: true,
|
|
14
|
-
minify: true,
|
|
15
|
-
config: 'tsconfig.json',
|
|
16
|
-
});
|