-
Notifications
You must be signed in to change notification settings - Fork 0
Dev merge #32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ports in index.node.ts; add comprehensive Copilot instructions and build guidelines
- Removed unused peer dependency 'pino-pretty' from peerDependencies. - Cleaned up devDependencies by removing 'barrelsby' and 'typescript-eslint' duplicate entry. - Added '@types/luxon' and '@types/node' to devDependencies for better type support. - Removed the import of '@rollup/plugin-commonjs' from rollup.config.js as it was not being used.
…scope Co-authored-by: barluq <47695733+barluq@users.noreply.github.com>
Co-authored-by: barluq <47695733+barluq@users.noreply.github.com>
Optimize logger by creating single pino instance at module scope
Jan26 extended logging + AI
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request introduces several important enhancements and standardizations to the shared TypeScript library, focusing on improving logging, utility functions, and repository documentation and guidelines. The most significant changes include a complete refactor of the logging utilities, the addition of new URL and date helper functions, and the introduction of comprehensive repository and coding instructions. There are also updates to dependencies and minor cleanups.
Logging improvements:
src/node/logging/logger.tsto replace theAppLoggerclass with a set of functional, leveled logging utilities (loggyInfo,loggyDebug,loggyWarn,loggyTrace,loggyError,loggyFatal,loggyAppStart,loggyRequestReceived,loggyResponseSent). These provide more granular and flexible logging for Node.js applications. ([src/node/logging/logger.tsL1-R141](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-e60e8bac8c505a9174a439038848d23a1d2bbfa242e49ae6aa004b3a9e4d7555L1-R141))src/index.node.tsto export the new logging functions instead of the previous class and type. ([src/index.node.tsL11-R11](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-ab1d6894726b864036e597060eeb8f2fcb96027911cf36c14b22e102980a5658L11-R11))Utility function additions:
isUrlandisArrayOfUrlshelper functions tosrc/globals/coding/code.formating.tsfor URL validation, and exported them insrc/index.browser.ts. ([[1]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-7b6cdade1c6655707a42a706db92f381f6c2e92cf7b1dcbcf69827380d9bbfa6R1-R21),[[2]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-21ccc5f340d04ed35285bc4345802864b3534f9662a2e9c2451bd59ec0896884L12-R22))nowPlusTimeinsrc/globals/coding/code.dates.tsto compute a future/past timestamp by adding seconds to the current time, and exported it insrc/index.browser.ts. ([[1]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-d350bbb0bb8728ce07a8e87aa8830d46336ac74ba1c281566a15560fc8359aebR14-R22),[[2]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-21ccc5f340d04ed35285bc4345802864b3534f9662a2e9c2451bd59ec0896884L12-R22))Repository documentation and guidelines:
.github/copilot-instructions.mdandAGENTS.md, outlining repository structure, build, testing, and coding standards. ([.github/copilot-instructions.mdR1-R48](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-227c2c26cb2ee0ce0f46a320fc48fbcbdf21801a57f59161b1d0861e8aad55f5R1-R48)).github/instructions/build.instructions.md,.github/instructions/coding.instructions.md, and.github/instructions/testing.instructions.md, providing explicit build, coding, and testing guidelines for contributors. ([[1]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-ff1a5ea86cba912472dc863f89e8fcdd0e5f3c8b0d3adcdf366062170c4a9ef2R1-R15),[[2]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-59ceb5614a0acc3fbc17c325d1c2b1d901136704f1aaef9960c5f9137d130bffR1-R17),[[3]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-96340ffca94eca2de77908cabb6fb7e7b0ef3589aa61d38bcc64e6a354fa4542R1-R23))Dependency and configuration updates:
package.jsonto version0.0.3-dev.0, adjusted peer and dev dependencies, and removed unused packages such aspino-prettyandbarrelsby. ([[1]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519L3-R3),[[2]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519L37-L55),[[3]](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519R60))barrelsby.jsonconfiguration file. ([outdated/barrelsby.jsonL1-L9](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-9620fe393ef41e3975c9747f8c3bc884aef2bd16fc2441f13be1d5d53ef8c0e0L1-L9))rollup.config.jsby removing the unused@rollup/plugin-commonjsimport. ([rollup.config.jsL4](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-6814bf77564b4f1c92f5861e184e28fe217c080a047fefa8b73a728f755ec45cL4))Minor configuration changes:
eslint.config.mjsfor consistency. ([eslint.config.mjsL22-R22](https://github.com/Gisat/ptr-be-core/pull/32/files#diff-9601a8f6c734c2001be34a2361f76946d19a39a709b5e8c624a2a5a0aade05f2L22-R22))These changes collectively improve the maintainability, clarity, and robustness of the codebase, while providing clear guidelines for future development.