UNPKG

restifyx.js

Version:

Advanced API endpoint handler system with automatic documentation

48 lines (47 loc) 1.43 kB
import type { RestifyOptions } from "./types/options"; import { RestifyXApp } from "./core/RestifyXApp"; /** * Creates and initializes a new RestifyX application instance. * * This function is the main entry point to start a RESTful API server * with integrated Express and Socket.IO support, configured using * the provided options. * * @example * \`\`\`typescript * import { create } from 'restifyx.js'; * * const app = create({ * port: 3000, * debug: true * }); * * async function start() { * await app.setup(); * await app.start(); * } * * start().catch(console.error); * \`\`\` * * @param options - Configuration options to customize the server's behavior and features. * @returns A fully configured instance of RestifyXApp ready to start serving. */ export declare function create(options?: RestifyOptions): RestifyXApp; export * from "./types/options"; export * from "./types/endpoint"; export * from "./core/errors/ApiError"; export * from "./core/errors/ErrorHandler"; export * from "./utils/logger"; export * from "./decorators"; export * from "./utils/cache"; export * from "./utils/rate-limiter"; export * from "./utils/security"; export * from "./utils/performance"; export * from "./fluent"; export { WebSocketManager } from "./core/WebSocketManager"; export { RestifyXApp } from "./core/RestifyXApp"; declare const _default: { create: typeof create; }; export default _default;