Skip to content

Commit ba76fba

Browse files
fixing job slug error
1 parent 06ff1d2 commit ba76fba

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/components/jobs/jobCard.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import JobCardCategory from "./jobCardCategory.astro";
55
import dayjs from "dayjs";
66
77
const { job } = Astro.props;
8-
const jobUrl = `/empleos/${dayjs(job.pubDate).format("YYYY--MM-DD")}/${job.slug}`;
8+
const jobUrl = `/empleos/${dayjs(job.pubDate).format("YYYY-MM-DD")}/${job.slug}`;
99
1010
const locationLabel = job.location ? job.location : "Presencial";
1111
const display_date = dayjs(job.pubDate).format("DD/MM/YY");

src/components/jobs/othersJobsCta.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import dayjs from "dayjs";
1111
{
1212
jobs.map((job) => (
1313
<li class="w-full py-3">
14-
<a href={`/empleos/${dayjs(job.pubDate).format("YYYY--MM-DD")}/${job.slug}`}>
14+
<a href={`/empleos/${dayjs(job.pubDate).format("YYYY-MM-DD")}/${job.slug}`}>
1515
<div class="font-medium text-base pb-1 text-gray-900 dark:text-gray-100">{job.title}</div>
1616
<div class="text-sm text-gray-600 dark:text-gray-300 line-clamp-1">{job.description.substring(0, 256)}</div>
1717
</a>

src/pages/empleos/[...slug].astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export async function getStaticPaths() {
1212
1313
return allJobs.map((job, index) => {
1414
let nextJobs = allJobs.slice(index + 1, index + 5);
15-
return { params: { slug: `${dayjs(job.pubDate).format("YYYY--MM-DD")}/${job.slug}` }, props: { job, nextJobs } };
15+
return { params: { slug: `${dayjs(job.pubDate).format("YYYY-MM-DD")}/${job.slug}` }, props: { job, nextJobs } };
1616
});
1717
}
1818

0 commit comments

Comments
 (0)