mirror of
https://github.com/pebble-dev/clay.git
synced 2026-08-27 20:36:33 -04:00
* feat: add ambient module stubs for declaration generation Provide TypeScript ambient declarations for 'message_keys' (Pebble SDK module) and './tmp/config-page.html' (build artefact) so tsc can resolve these imports when generating .d.ts files. * feat: add tsconfig for declaration generation Configures tsc --allowJs --emitDeclarationOnly to generate per-file .d.ts reference output in dist-types/ from the library source files. * feat: add curated TypeScript declarations for public API Hand-curated index.d.ts covering Clay, ClayConfig, ClayItem, ClayEvents, manipulators, and all supporting types. Necessary because tsc cannot infer the ClayEvents mixin or dynamically-bound manipulator methods. All types are exported via the Clay namespace. * test: add type-checking verification for index.d.ts Exercises the full public API surface — constructor, instance/static methods, ClayConfig/ClayItem event methods, manipulator methods, namespace-exported types, and customFn this-context. * build: add typescript devDependency, types field, and build scripts Adds typescript 6.0.2 as a devDependency. Sets "types": "index.d.ts" in package.json. Adds build:types and check:types scripts. * build: add gulp types task to validate declarations on build Validates index.d.ts against test/type-checks.ts as part of the default gulp build. Reference declaration generation via build:types remains available as a separate manual step. * chore: update ignore files for TypeScript declarations Add dist-types/ to .gitignore (build artefact). Whitelist index.d.ts in .npmignore so type declarations ship with the package. * ci: add typecheck workflow to validate TypeScript declarations Runs npm run check:types on push and PR to main, matching the existing lint/test/build workflow pattern.
19 lines
326 B
Plaintext
Executable File
19 lines
326 B
Plaintext
Executable File
# Coverage directory used by tools like istanbul
|
|
/coverage
|
|
|
|
# node-waf configuration
|
|
.lock-wscript
|
|
/.lock-waf_*_build
|
|
|
|
# Dependency directory
|
|
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
|
|
/node_modules
|
|
/npm-debug.log
|
|
|
|
/tmp/
|
|
/src/js/index.js
|
|
/dist.zip
|
|
/dist/
|
|
/build/
|
|
/dist-types/
|