Home / File/ routing-priority.test.js — astro Source File

routing-priority.test.js — astro Source File

Architecture documentation for routing-priority.test.js, a javascript file in the astro codebase. 5 imports, 0 dependents.

Entity Profile

Dependency Diagram

graph LR
  ce87be7f_173d_aa32_231c_ab97b8d2eeba["routing-priority.test.js"]
  0a624eac_945e_c9e8_c9de_3feb9de2dd15["test-utils.js"]
  ce87be7f_173d_aa32_231c_ab97b8d2eeba --> 0a624eac_945e_c9e8_c9de_3feb9de2dd15
  dd4f09ce_3fd7_8295_f616_8876cda4555c["loadFixture"]
  ce87be7f_173d_aa32_231c_ab97b8d2eeba --> dd4f09ce_3fd7_8295_f616_8876cda4555c
  e1e2fac7_5a95_7a88_cb1e_0a3b91c4e607["strict"]
  ce87be7f_173d_aa32_231c_ab97b8d2eeba --> e1e2fac7_5a95_7a88_cb1e_0a3b91c4e607
  6b0635f9_51ea_77aa_767b_7857878e98a6["node:test"]
  ce87be7f_173d_aa32_231c_ab97b8d2eeba --> 6b0635f9_51ea_77aa_767b_7857878e98a6
  deb87372_5629_35f8_9a54_e755a08f776a["cheerio"]
  ce87be7f_173d_aa32_231c_ab97b8d2eeba --> deb87372_5629_35f8_9a54_e755a08f776a
  style ce87be7f_173d_aa32_231c_ab97b8d2eeba fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import assert from 'node:assert/strict';
import { after, before, describe, it } from 'node:test';
import { load as cheerioLoad } from 'cheerio';
import { loadFixture } from './test-utils.js';

const routes = [
	{
		description: 'matches / to index.astro',
		url: '/',
		h1: 'index.astro',
	},
	{
		description: 'matches /slug-1 to [slug].astro',
		url: '/slug-1',
		h1: '[slug].astro',
		p: 'slug-1',
	},
	{
		description: 'matches /slug-2 to [slug].astro',
		url: '/slug-2',
		h1: '[slug].astro',
		p: 'slug-2',
	},
	{
		description: 'matches /page-1 to [page].astro',
		url: '/page-1',
		h1: '[page].astro',
		p: 'page-1',
	},
	{
		description: 'matches /page-2 to [page].astro',
		url: '/page-2',
		h1: '[page].astro',
		p: 'page-2',
	},
	{
		description: 'matches /posts/post-1 to posts/[pid].astro',
		url: '/posts/post-1',
		h1: 'posts/[pid].astro',
		p: 'post-1',
	},
	{
		description: 'matches /posts/post-2 to posts/[pid].astro',
		url: '/posts/post-2',
		h1: 'posts/[pid].astro',
		p: 'post-2',
	},
	{
		description: 'matches /posts/1/2 to posts/[...slug].astro',
		url: '/posts/1/2',
		h1: 'posts/[...slug].astro',
		p: '1/2',
	},
	{
		description: 'matches /de to de/index.astro',
		url: '/de',
		h1: 'de/index.astro (priority)',
	},
	{
		description: 'matches /en to [lang]/index.astro',
// ... (211 more lines)

Subdomains

Dependencies

Frequently Asked Questions

What does routing-priority.test.js do?
routing-priority.test.js is a source file in the astro codebase, written in javascript. It belongs to the IntegrationAdapters domain, SsrAdapters subdomain.
What functions are defined in routing-priority.test.js?
routing-priority.test.js defines 1 function(s): appendForwardSlash.
What does routing-priority.test.js depend on?
routing-priority.test.js imports 5 module(s): cheerio, loadFixture, node:test, strict, test-utils.js.
Where is routing-priority.test.js in the architecture?
routing-priority.test.js is located at packages/astro/test/routing-priority.test.js (domain: IntegrationAdapters, subdomain: SsrAdapters, directory: packages/astro/test).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free