@small-web/kitten-types 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.
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="WEB_MODULE" version="4">
3
+ <component name="NewModuleRootManager">
4
+ <content url="file://$MODULE_DIR$" />
5
+ <orderEntry type="inheritedJdk" />
6
+ <orderEntry type="sourceFolder" forTests="false" />
7
+ </component>
8
+ </module>
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/kitten-types.iml" filepath="$PROJECT_DIR$/.idea/kitten-types.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
package/.idea/vcs.xml ADDED
@@ -0,0 +1,7 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="" vcs="Git" />
5
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
6
+ </component>
7
+ </project>
package/CHANGELOG.md CHANGED
@@ -4,6 +4,16 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [1.0.2] - 2026-06-26
8
+
9
+ ### Improved
10
+
11
+ - Documentation
12
+
13
+ ### Fixed
14
+
15
+ - Polka router export (as referenced at `kitten.app.router`).
16
+
7
17
  ## [1.0.1] - 2026-06-26
8
18
 
9
19
  ### Added
package/global.d.ts CHANGED
@@ -1009,7 +1009,22 @@ export interface kitten {
1009
1009
  /**
1010
1010
  The app data directory for the current app (site/project).
1011
1011
 
1012
- Set to the return value of {@link utils.getProjectIdentifierForDomain} in {@link KITTEN_DATA_DIRECTORY}.
1012
+ Use when opening your database in a Database App Module to get the path to it.
1013
+
1014
+ @example
1015
+ JSDB.open(
1016
+ path.join(kitten.paths.APP_DATA_DIRECTORY, 'db'),
1017
+ {
1018
+ compactOnLoad,
1019
+ classes: [
1020
+ Database,
1021
+ Kitten
1022
+ ]
1023
+ }
1024
+ )
1025
+
1026
+ @see https://kitten.small-web.org/tutorials/database-app-modules/
1027
+ @see https://codeberg.org/kitten/app/src/branch/main/examples/database-app-module/app_modules/database/database.js#L46
1013
1028
  */
1014
1029
  APP_DATA_DIRECTORY: string
1015
1030
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@small-web/kitten-types",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "Types-only package for Kitten: declares global `kitten` namespace and exports Kitten types.",
5
5
  "types": "index.d.ts",
6
6
  "exports": {
package/types.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import EventEmitter from 'node:events'
2
+ import type polka from 'polka'
2
3
 
3
4
  /**
4
5
  Represents a browser session.
@@ -39,7 +40,7 @@ export class Session extends EventEmitter {
39
40
 
40
41
  export type { default as WebSocket, BufferLike } from './ws/index.d.ts'
41
42
  export type { default as slugify } from './slugify/index.d.ts'
42
- export type { default as Polka } from './polka/index.d.ts'
43
+ export type Polka = ReturnType<typeof polka>
43
44
  export { default as MarkdownIt } from 'markdown-it'
44
45
 
45
46
  export namespace yaml {