@nx/remix 23.1.1 → 23.1.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.
@@ -6,7 +6,6 @@ const tslib_1 = require("tslib");
6
6
  const internal_1 = require("@nx/devkit/internal");
7
7
  const devkit_1 = require("@nx/devkit");
8
8
  const js_1 = require("@nx/js");
9
- const onboarding_1 = require("nx/src/nx-cloud/utilities/onboarding");
10
9
  const testing_config_utils_1 = require("../../utils/testing-config-utils");
11
10
  const versions_1 = require("../../utils/versions");
12
11
  const init_1 = tslib_1.__importDefault(require("../init/init"));
@@ -56,9 +55,9 @@ async function remixApplicationGeneratorInternal(tree, _options) {
56
55
  }
57
56
  const installTask = (0, update_dependencies_1.updateDependencies)(tree);
58
57
  tasks.push(installTask);
59
- const onBoardingStatus = await (0, onboarding_1.createNxCloudOnboardingURLForWelcomeApp)(tree, options.nxCloudToken);
58
+ const onBoardingStatus = await (0, internal_1.createNxCloudOnboardingURLForWelcomeApp)(tree, options.nxCloudToken);
60
59
  const connectCloudUrl = onBoardingStatus === 'unclaimed' &&
61
- (await (0, onboarding_1.getNxCloudAppOnBoardingUrl)(options.nxCloudToken));
60
+ (await (0, internal_1.getNxCloudAppOnBoardingUrl)(options.nxCloudToken));
62
61
  const vars = {
63
62
  ...options,
64
63
  tmpl: '',
@@ -21,8 +21,7 @@ export default function handleRequest(
21
21
  remixContext: EntryContext,
22
22
  // This is ignored so we can keep it in the template for visibility. Feel
23
23
  // free to delete this parameter in your app if you're not using it!
24
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
25
- loadContext: AppLoadContext
24
+ _loadContext: AppLoadContext
26
25
  ) {
27
26
  return isbot(request.headers.get("user-agent") || "")
28
27
  ? handleBotRequest(
@@ -13,5 +13,5 @@ test('renders loader data', async () => {
13
13
 
14
14
  render(<RemixStub />);
15
15
 
16
- await screen.findByText('Hello there,');
16
+ expect(await screen.findByText('Hello there,')).toBeTruthy();
17
17
  });
@@ -3,7 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.default = default_1;
4
4
  const tslib_1 = require("tslib");
5
5
  const devkit_1 = require("@nx/devkit");
6
- const devkit_2 = require("@nx/devkit");
7
6
  const application_impl_1 = tslib_1.__importDefault(require("../application/application.impl"));
8
7
  const setup_impl_1 = tslib_1.__importDefault(require("../setup/setup.impl"));
9
8
  const normalize_options_1 = require("./lib/normalize-options");
@@ -31,5 +30,5 @@ async function default_1(tree, _options) {
31
30
  tree.delete('apps');
32
31
  tree.delete('libs');
33
32
  await (0, devkit_1.formatFiles)(tree);
34
- return (0, devkit_2.runTasksInSerial)(...tasks);
33
+ return (0, devkit_1.runTasksInSerial)(...tasks);
35
34
  }
@@ -2,8 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createNodesV2 = exports.createNodes = exports.createDependencies = void 0;
4
4
  const internal_1 = require("@nx/devkit/internal");
5
- const cache_directory_1 = require("nx/src/utils/cache-directory");
6
- const file_hasher_1 = require("nx/src/hasher/file-hasher");
7
5
  const devkit_1 = require("@nx/devkit");
8
6
  const js_1 = require("@nx/js");
9
7
  const path_1 = require("path");
@@ -21,8 +19,8 @@ const remixConfigGlob = '**/{remix,vite}.config.{js,cjs,mjs,ts,cts,mts}';
21
19
  exports.createNodes = [
22
20
  remixConfigGlob,
23
21
  async (configFilePaths, options, context) => {
24
- const optionsHash = (0, file_hasher_1.hashObject)(options);
25
- const cachePath = (0, path_1.join)(cache_directory_1.workspaceDataDirectory, `remix-${optionsHash}.hash`);
22
+ const optionsHash = (0, internal_1.hashObject)(options);
23
+ const cachePath = (0, path_1.join)(internal_1.workspaceDataDirectory, `remix-${optionsHash}.hash`);
26
24
  const targetsCache = new internal_1.PluginCache(cachePath);
27
25
  const packageManager = (0, devkit_1.detectPackageManager)(context.workspaceRoot);
28
26
  const pmc = (0, devkit_1.getPackageManagerCommand)(packageManager);
@@ -3,9 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createWatchPaths = createWatchPaths;
4
4
  exports.getRelativeDependencyPaths = getRelativeDependencyPaths;
5
5
  const devkit_1 = require("@nx/devkit");
6
- const find_project_for_path_1 = require("nx/src/project-graph/utils/find-project-for-path");
7
- const project_graph_utils_1 = require("nx/src/utils/project-graph-utils");
8
6
  const path_1 = require("path");
7
+ const internal_1 = require("@nx/devkit/internal");
9
8
  /**
10
9
  * Generates an array of paths to watch based on the project dependencies.
11
10
  *
@@ -13,9 +12,9 @@ const path_1 = require("path");
13
12
  */
14
13
  async function createWatchPaths(dirname) {
15
14
  const graph = await (0, devkit_1.createProjectGraphAsync)();
16
- const projectRootMappings = (0, find_project_for_path_1.createProjectRootMappings)(graph.nodes);
17
- const projectName = (0, find_project_for_path_1.findProjectForPath)((0, path_1.relative)(devkit_1.workspaceRoot, dirname), projectRootMappings);
18
- const deps = (0, project_graph_utils_1.findAllProjectNodeDependencies)(projectName, graph);
15
+ const projectRootMappings = (0, internal_1.createProjectRootMappings)(graph.nodes);
16
+ const projectName = (0, internal_1.findProjectForPath)((0, path_1.relative)(devkit_1.workspaceRoot, dirname), projectRootMappings);
17
+ const deps = (0, internal_1.findAllProjectNodeDependencies)(projectName, graph);
19
18
  return getRelativeDependencyPaths(graph.nodes[projectName], deps, graph);
20
19
  }
21
20
  // Exported for testing
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nx/remix",
3
- "version": "23.1.1",
3
+ "version": "23.1.2",
4
4
  "description": "The Remix plugin for Nx contains executors and generators for managing Remix applications and libraries within an Nx workspace. It provides:\n\n\n- Integration with libraries such as Vitest, Jest, Playwright, Cypress, and Storybook.\n\n- Generators for applications, libraries, routes, loaders, and more.\n\n- Library build support for publishing packages to npm or other registries.\n\n- Utilities for automatic workspace refactoring.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -56,20 +56,20 @@
56
56
  "dependencies": {
57
57
  "tslib": "^2.3.0",
58
58
  "@phenomnomnominal/tsquery": "~6.2.0",
59
- "@nx/devkit": "23.1.1",
60
- "@nx/js": "23.1.1",
61
- "@nx/react": "23.1.1",
62
- "@nx/web": "23.1.1"
59
+ "@nx/react": "23.1.2",
60
+ "@nx/devkit": "23.1.2",
61
+ "@nx/js": "23.1.2",
62
+ "@nx/web": "23.1.2"
63
63
  },
64
64
  "devDependencies": {
65
- "@nx/eslint": "23.1.1",
66
- "nx": "23.1.1",
67
- "@nx/vitest": "23.1.1"
65
+ "@nx/eslint": "23.1.2",
66
+ "nx": "23.1.2",
67
+ "@nx/vitest": "23.1.2"
68
68
  },
69
69
  "peerDependencies": {
70
70
  "@remix-run/dev": "^2.0.0",
71
- "@nx/cypress": "23.1.1",
72
- "@nx/playwright": "23.1.1"
71
+ "@nx/cypress": "23.1.2",
72
+ "@nx/playwright": "23.1.2"
73
73
  },
74
74
  "peerDependenciesMeta": {
75
75
  "@nx/cypress": {