skott

All-in-one devtool to automatically analyze, search and visualize dependencies from JavaScript, TypeScript (JSX/TSX) and Node.js (ES6, CommonJS)

MIT License

Downloads
138.5K
Stars
545
Committers
11

Bot releases are visible (Hide)

skott - [email protected] Latest Release

Published by github-actions[bot] 4 months ago

Minor Changes

  • #162 b13d3c9 Thanks @antoine-coulon! - Allow unused files to be tracked and reported. From the CLI, --showUnusedFiles can be used to report unused files. From the API, a new collectUnusedFiles method is accessible through the graph API:

    import skott from "skott";
    
    const instance = await skott();
    const unusedFiles = instance.useGraph().collectUnusedFiles();
    

    This version also includes a fix for a bug related to --trackBuiltinDependencies and --trackThirdPartyDependencies that were not propagated anymore (since 0.34.0) when being provided from the CLI.

  • #161 4d19c97 Thanks @antoine-coulon! - Add support for multiple ignore patterns:

    • the CLI can now accumulate multiple ignore patterns such as skott --ignorePattern=X --ignorePattern=Y
    • the API configuration now takes a ignorePatterns property instead of a single ignorePattern (breaking change).

Patch Changes

skott - [email protected]

Published by github-actions[bot] 4 months ago

Patch Changes

skott - [email protected]

Published by github-actions[bot] 4 months ago

Minor Changes

  • #157 0871131 Thanks @antoine-coulon! - Expose a new rendering module providing a programmatic access to terminal and web visualizations through skott's API.

    This is equivalent to use the CLI such as skott --displayMode=webapp but offers more flexibility for the runtime configuration which suffers from limitations when only using the CLI (some configurations are nearly impossible to represent using strings e.g. providing custom functions), this is why often authors tend to introduce runtime configuration files that CLIs can pick up automatically, thing that we want to avoid with skott, by unifying it's usage either coming from the API or CLI.

    Using the rendering module

    import { defaultConfig } from "skott";
    import { Web, Terminal } from "skott/rendering";
    
    await Web.renderWebApplication(
      // skott runtime config
      defaultConfig,
      // application config
      {
        visualization: {
          granularity: "module",
        },
        watch: true,
        port: 1111,
        onListen: (port) => console.log(`Listening on port ${port}`),
        open: true,
        onOpenError: () => console.log(`Error when opening the browser`),
      },
    );
    
    await Terminal.renderTerminalApplication(defaultConfig, {
      displayMode: "graph",
      exitCodeOnCircularDependencies: 1,
      showCircularDependencies: true,
      showUnusedDependencies: true,
      watch: true,
    });
    
skott - [email protected]

Published by github-actions[bot] 7 months ago

Minor Changes

  • #145 2c00723 Thanks @antoine-coulon! - Add GitHub tarball fetcher to be able to pull public repositories as .zip (used in skott's benchmark).

    Switch to an Effect-based API.

skott - [email protected]

Published by github-actions[bot] 7 months ago

Patch Changes

  • #152 9d43673 Thanks @antoine-coulon! - Remove @typescript-eslint/typescript-estree warning occurring when an incompatible version of TypeScript is found by ensuring fixed compatible versions from the manifest.
skott - [email protected]

Published by github-actions[bot] 7 months ago

Patch Changes

  • #150 04fe22d Thanks @antoine-coulon! - This patch fixes the eager evaluation of cwd default value from the config preventing process.chdir
    to work as expected when used before invoking skott's API.

    process.chdir("/tmp/somewhere");
    
    // skott is now being executed at the root of "/tmp/somewhere"
    
    const instance = await skott();
    

    Note: regarding the generated graph relationships, this is pretty much equivalent as doing skott({ cwd: "/tmp/somewhere" }), even though
    node paths will be relative and won't have the same values as the later still executes skott from the script location
    and not from /tmp/somewhere. In other words, using cwd parameter will have node paths being relative to skott's script location, while using
    process.chdir will make skott execute the script from the provided directory.

    You can find a real example of the difference between node paths using process.chdir and cwd: https://github.com/antoine-coulon/skott/issues/149#issuecomment-1989451725
    by @mattkindy.

skott - [email protected]

Published by antoine-coulon 8 months ago

What's Changed

New Contributors

Full Changelog: https://github.com/antoine-coulon/skott/compare/v0.32.0...0.33.0

skott - [email protected]

Published by github-actions[bot] 9 months ago

Patch Changes

  • #138 4a3bd27 Thanks @pedrolamas! - Fixes high severity vulnerability in lodash.* dependency by replacing it with lodash-es
skott - [email protected]

Published by github-actions[bot] 9 months ago

Minor Changes

  • #131 777998c Thanks @antoine-coulon! - Add watch mode through --watch cli option that can be used with all display modes:

    • using with --displayMode=webapp (default)

    Changes will fully re-render the graph with its new content. Changes are not atomic yet, meaning that even if only one file is changed, the graph is being re-rendered anyway. Note that this might be improved in the future.

    • using with --displayMode=file-tree or --displayMode=graph

    Changes will clear the terminal and output the new computed graph with other information depending on selected options (--showCircularDependencies etc).

    • using with --displayMode=raw

    Changes will clear the terminal and output the new information depending on selected options (--showCircularDependencies, etc). As usual with raw mode, the graph is not rendered.

    Few breaking changes:

    • using --showCircularDependencies and --showUnusedDependencies together with --displayMode=webapp will throw error. This is because these options were thought to be used in the context of cli output which is not very useful when using the webapp.

    Note that the web application has an option to show circular dependencies without the need for the --showCircularDependencies to be provided. The same for --showUnusedDependencies will be done in the next versions, for now showing unused dependencies is only supported using raw, file-tree or graph display modes.

Patch Changes

skott - [email protected]

Published by github-actions[bot] 10 months ago

Patch Changes

skott - [email protected]

Published by github-actions[bot] about 1 year ago

Patch Changes

  • #121 06674a0 Thanks @robertoyoc! - Resolve index.jsx and index.tsx when they are being imported from . and ./ declarations.
skott - [email protected]

Published by antoine-coulon about 1 year ago

Patch Changes

skott - [email protected]

Published by github-actions[bot] about 1 year ago

Patch Changes

skott - [email protected]

Published by github-actions[bot] about 1 year ago

Patch Changes

skott - [email protected]

Published by github-actions[bot] about 1 year ago

Minor Changes

  • #72 1d4b302 Thanks @antoine-coulon! - Introduce new skott web application (v2), can be used starting from [email protected]
    No breaking changes introduced from a skott perspective, skott --displayMode=webapp is still the way to go.

Patch Changes

skott - [email protected]

Published by github-actions[bot] about 1 year ago

Major Changes

  • #72 1d4b302 Thanks @antoine-coulon! - Introduce new skott web application (v2), can be used starting from [email protected]
    No breaking changes introduced from a skott perspective, skott --displayMode=webapp is still the way to go.
skott - [email protected]

Published by github-actions[bot] about 1 year ago

Patch Changes

  • #112 f41de8b Thanks @antoine-coulon! - Use localhost instead of 127.0.0.1 to ensure a better cross platform compatibility when auto opening the web application. Thanks @HassanMojab for the hint!
skott - [email protected]

Published by github-actions[bot] about 1 year ago

Patch Changes

  • #110 ad5e4be Thanks @antoine-coulon! - Use cmd.exe (natively installed on WSL) instead of wslview to auto open browser when using webapp display mode
skott - [email protected]

Published by github-actions[bot] about 1 year ago

Patch Changes

  • #108 5f1d31b Thanks @antoine-coulon! - Allow web application to be automatically opened on WSL via wslview. Better error handling when the application can't be automatically opened.
skott - [email protected]

Published by github-actions[bot] about 1 year ago

Minor Changes

  • #105 6ddda95: Improve TypeScript type-level import specifiers import { type X }

Before, only import type { X } was discarded when not tracking type-level imports. Now, both are supported and considered as type-level imports.

import { type A } from "a"; 
import type { B } from "b";