370 Commits

Author SHA1 Message Date
Insomnia
2fcbf833a6 Bump app version to 13.1.0 (#10296) 2026-07-24 09:50:49 +08:00
Jack Kavanagh
54a23e3bbb refactor: remove dead vite config stubs and fix stale comments (#10026)
* refactor: remove dead vite.config stubs and fix comments

- Remove @apidevtools/swagger-parser and mocha from externalDependencies since both
  are only used in the main process (importers and IPC handler), never in the renderer
- Update stale comment claiming nodeIntegration: true is still used
- Remove misleading insomnia-testing example from SSR conditions comment
- Remove main/types fields from insomnia-testing package.json since they point to
  a non-existent src/index.ts; all consumers use explicit deep path imports

* refactor: remove unused assert polyfill alias, clarify dep chain in comments

- Remove assert/node:assert aliases — no renderer consumer (jshint, isomorphic-git, events, tough-cookie) requires 'assert'
- Condense polyfill comments to show only the evidence (which library needs it)
- Update util comment from tough-cookie (moved to main process) to jshint (actual renderer consumer)

* clean up vite config

* fix lint
2026-06-04 09:35:02 +00:00
Jack Kavanagh
79c544238b feat: disable nodeIntegration in renderer mainWindow, remove Node import check tooling (#9996)
* Add vault-crypto/mime utilities and remove heavyweight third-party imports

- Add AES-GCM vault-crypto utility with tests (replaces node-forge usage)
- Add common/mime.ts to replace mime-types package dependency
- Replace tough-cookie import in response-cookies-viewer with inline parser
- Replace @grpc/grpc-js status import in grpc-status-tag with inline constant
- Replace electron.ipcRenderer in auth.clear-vault-key with showToast()
- Remove unused analytics call from window-utils

* Fix impure Date.now() key on CodeEditor; use setValue via ref instead

Replace key={Date.now()} with a useEffect that calls editorRef.current.setValue(snippet)
whenever snippet changes, keeping the editor mounted. Also apply prettier fixes from quick-check.

* fix: address Copilot review comments on PR #9992

- vault-crypto: replace forge-in-renderer with IPC bridge (main process
  retains forge; renderer calls window.main.vault.{en,de}cryptSecretValue)
- mime.ts: expand lookup table to 48 entries (webp, wasm, mp4, docx, xlsx,
  fonts, audio/video, etc.) and fix remaining mime-types import in send route
- response-viewer: move charset alias map to module level; normalise iconv-lite
  alias names (utf8, latin1, win1252, …) to WHATWG labels for TextDecoder
- auth.clear-vault-key: fix typo "all you local" → "all your local"

* fix: sort imports in send route

* feat: disable nodeIntegration in renderer mainWindow, remove import check tooling

- Set nodeIntegration:false and contextIsolation:true on mainWindow webPreferences
  (hidden window keeps nodeIntegration:true for user script execution)
- Split script-security-rules.ts out of script-security-policy.ts so the renderer
  can import display-only constants without pulling in require-interceptor
- Add templating/renderer-safe.ts with Node-free render/reload/getTagDefinitions;
  update all renderer callers to import from it instead of templating/index
- Split insomnia-testing generate.ts: move generateToFile to generate-to-file.ts
  so generate() has no Node imports; expose generateToFile from new entry point
- Move runTests execution to main process via IPC (run-tests channel) so the
  renderer routes no longer import the Mocha-backed test runner directly
- Delete vite-plugin-electron-node-require.ts, check-renderer-node-imports.ts,
  renderer-node-import-baseline.json and all related scripts/plugins now that the
  renderer bundle is free of Node built-in imports

* fix: sort imports, use static TestResults type, remove unused analytics import

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* remove mime stuff

* remove ci step

* update plan

* insomnia testing adapter

* use export method

* trick react router ssr

* add renderer errors

* globalThis

* improve error

* move plugin types

* ipc validate proto

* fix import

* plugin types

* polyfill events for jshint

* restore node require plugin

* vault adapter

* add crypto bridges

* tough-cookie ipc

* util stub

* split cookie into network adapter

* assert

* fix plugin index import

* serialise cookie

* decouple renderer from scripting

* Fix rebase conflicts and import path issues

- Fix incorrect ~/insomnia-data imports (should be insomnia-data package)
- Remove non-existent mime utility imports and provide simple fallback
- Remove incorrect analytics call from main process
- Remove unused imports (Settings, Cookie)
- Fix Response type annotation for getResponseBodyBuffer

* lint

* fix tests

* fix: use dynamic import for crypt in session.ts for main process compatibility

The session.ts module is used in both renderer and main process contexts (via sync.invoke IPC handlers). When running in the main process, window.main is undefined, causing TypeError when trying to access window.main.crypt.decryptAES().

Changes:
- Use dynamic import of crypt module (only loaded in main process context)
- In renderer: window.main.crypt is always available so dynamic import never executes
- In main process: dynamic import loads crypt with node:crypto support
- Protect loginStateChange() calls with window existence checks

This avoids bundling node:crypto in the Vite renderer build while still supporting both execution contexts.

Fixes E2E test failures in sync operations (remoteBackendProjects, _assertSession, etc.) caused by disabled nodeIntegration.

* fix: add aria-label to template tag preview and browser-safe encoding fallback

- Add aria-label="Live Preview" to textarea in TagEditor for better Playwright accessibility
- Add atob() fallback for decodeEncoding in browser contexts where Buffer isn't available
- Fixes smoke test element discovery for template tag preview modal

* fix: add explicit waits for element stability in environment test

Add toBeEnabled() and toBeVisible() waits before clicking elements in the
'kv pair environment can be updated' test. This prevents timeout errors from
unstable/flickering elements during modal interactions, especially in
high-concurrency shard execution.

* remove unused

* add autocomplete generate test step

* fix lint

* put analytics back in

* combine vault and crypto adapter

* remove unused export split

* remove insomnia-testing cruft, addressing feedback

* fix: use direct imports in insomnia-inso after insomnia-testing index.ts removal

* fix circular reference

* fix: move createElectronNotifier to main process to fix SSR error

Move the electron-dependent createElectronNotifier function from repo-file-watcher.ts
to git-service.ts to prevent electron imports from being evaluated in the renderer/SSR context.

* export har ipc bridge

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-04 13:40:44 +08:00
Bingbing
b09cde814d refactor: extract insomnia-data into workspace package (#10010)
Move insomnia-data models, services, database code, and common utilities into a dedicated workspace package. Update consumers to import from the new package entrypoints and declare workspace dependencies for the extracted package.
2026-06-02 09:49:10 +00:00
Insomnia
b18f9528fc Bump app version to 12.5.1-alpha.0 2026-04-11 00:15:09 +00:00
Ryan Willis
52d64a0116 chore(deps): bump dependencies (#9756) 2026-04-03 19:08:00 -04:00
Insomnia
33e0c2e2e2 Bump app version to 12.5.0 2026-04-01 21:51:11 +00:00
Insomnia
8f6bf2af2f Bump app version to 12.5.0-beta.0 2026-03-26 02:32:17 +00:00
Insomnia
0e30098049 Bump app version to 12.4.0 2026-03-04 23:55:20 +00:00
Insomnia
a7dbd115f9 Bump app version to 12.4.0-beta.0 2026-02-26 04:11:02 +00:00
Insomnia
58cc102bf8 Bump app version to 12.3.1 2026-02-05 05:24:10 +00:00
Insomnia
5d669097a9 Bump app version to 12.3.1-beta.1 2026-02-04 08:00:05 +00:00
Insomnia
a195fdf6a2 Bump app version to 12.3.1-beta.0 2026-02-02 00:05:36 +00:00
Insomnia
efdc35fd43 Bump app version to 12.3.0 2026-01-15 00:38:36 +00:00
Insomnia
04a1360620 Bump app version to 12.3.0-beta.0 2026-01-08 04:55:57 +00:00
Insomnia
da68781c30 Bump app version to 12.2.0 2025-12-19 00:24:44 +00:00
Insomnia
139791a4fb Bump app version to 12.2.0-beta.1 2025-12-16 19:56:31 +00:00
Insomnia
d0f07bf1d7 Bump app version to 12.2.0-beta.0 2025-12-12 09:15:42 +00:00
Jack Kavanagh
76fa0c2349 explicit noEmit (#9437) 2025-11-28 11:52:19 +00:00
Jack Kavanagh
c62a114d28 Chore: eslint-autofixes (#9421)
* sort and remove a few

* autofix 1

* remove useless undefined

* fix types

* number seperators

* native coercion

* utf8

* explicit number

* dom node dataset

* explicit unused catch

* array find

* fix types

* prefer negative index

* from code point

* fix error layout

* prefer ternary

* explicit length

* useless case

* named functions

* utf8

* import style

* default parameters

* no instance of

* clone

* use regex test

* single call

* prettier

* fix types

* Revert "use regex test"

This reverts commit 8fb9e991fffa9e3a51ff75cdc29dad331ed2fb66.
2025-11-27 09:36:52 +00:00
Insomnia
5d4f750b31 Bump app version to 12.1.0 2025-11-21 06:47:53 +00:00
Insomnia
0c640f58c1 Bump app version to 12.1.0-beta.1 2025-11-20 09:58:45 +00:00
Insomnia
1cec82cc26 Bump app version to 12.1.0-beta.0 2025-11-14 08:29:15 +00:00
Insomnia
62d56e3863 Bump app version to 12.0.0 2025-11-04 18:32:25 +08:00
Insomnia
18352b3ea7 Bump app version to 12.0.0-beta.0 2025-10-24 03:59:15 +00:00
Insomnia
605f21111d Bump app version to 11.6.2 2025-10-21 19:49:00 +00:00
Insomnia
0d9ff79bd2 Bump app version to 11.6.1 2025-09-18 06:46:23 +00:00
Insomnia
af7104f189 Bump app version to 11.6.0 2025-09-11 07:46:54 +00:00
Insomnia
0aa90e31d0 Bump app version to 11.6.0-beta.0 2025-09-05 07:42:11 +00:00
Insomnia
c46c54bd03 Bump app version to 11.5.0 2025-08-26 06:10:06 +00:00
Insomnia
614a70041d Bump app version to 11.5.0-beta.4 2025-08-25 09:51:04 +00:00
Insomnia
b927392764 Bump app version to 11.5.0-beta.3 2025-08-25 05:42:40 +00:00
Pavlos Koutoglou
8beb63f7da Bump app version to 11.5.0-beta.2 2025-08-21 14:07:05 +00:00
Jay Wu
efbd7c3900 Bump app version to 11.5.0-beta.1 2025-08-20 06:24:47 +00:00
Curry Yang
289bc96e18 Bump app version to 11.5.0-beta.0 2025-08-15 03:11:52 +00:00
Jay Wu
6137ff6cf9 Bump app version to 11.4.0 2025-07-30 09:06:55 +00:00
Curry Yang
25c66a6fce Bump app version to 11.4.0-beta.1 2025-07-29 10:15:28 +00:00
Curry Yang
d46b9a1e2a Bump app version to 11.4.0-beta.0 2025-07-24 10:58:09 +00:00
Jay Wu
37af3e3ea1 Bump app version to 11.3.0 2025-07-10 07:59:23 +00:00
Curry Yang
cc8ff00f23 Bump app version to 11.3.0-beta.1 2025-07-08 09:41:40 +00:00
Jay Wu
3b05ea17f8 Bump app version to 11.3.0-beta.0 2025-07-01 20:13:50 +08:00
Jay Wu
fa553a620c Bump app version to 11.2.0 2025-06-05 05:11:01 +00:00
Jay Wu
3f1004dde4 Bump app version to 11.2.0-beta.0 2025-05-30 13:05:49 +00:00
James Gatz
3145b57aa8 feat(Tests): Add require interceptor in tests (#8758)
* block requiring arbitary modules in test scripts

* cleanup log

* fix require/chai issues

* update tests
2025-05-28 08:59:45 +00:00
Jack Kavanagh
5543a6e08f tooling: unicorn eslint (#8743)
* set a few unicorn rules

* autofixes

* fix types

* more minor fixes

* more autofixes

* more normalisation

* prettier run
2025-05-27 09:47:46 +00:00
Jay Wu
0dd38ba87b Bump app version to 11.1.0 2025-05-06 05:41:09 +00:00
Jay Wu
96cc096511 Bump app version to 11.1.0-beta.4 2025-04-30 11:17:33 +00:00
Jay Wu
4608067c11 Bump app version to 11.1.0-beta.3 (#8664) 2025-04-30 10:57:39 +08:00
Jack Kavanagh
b30978e33b Full-prettier-run (#8605)
* prettier

* remove markdown linting
2025-04-11 13:37:19 +02:00
Jay Wu
46263a559a Bump app version to 11.1.0-beta.1 2025-04-09 06:28:31 +00:00