diff --git a/.eleventy.js b/.eleventy.js index 5f63ad1a..d9e38fff 100644 --- a/.eleventy.js +++ b/.eleventy.js @@ -1,7 +1,12 @@ const yaml = require("js-yaml"); +const MarkdownIt = require("markdown-it"); +const markdown = new MarkdownIt({ html: false }); module.exports = (eleventyConfig) => { eleventyConfig.addShortcode("currentYear", () => new Date().getFullYear()); + eleventyConfig.addFilter("markdown", (value) => + markdown.render(typeof value === "string" ? value : "") +); eleventyConfig.addFilter("safeJsonLd", (value) => { const json = JSON.stringify(value) ?? "null"; return json.replace(/<\//g, "<\\/"); diff --git a/package-lock.json b/package-lock.json index 202a5e00..6f8b9c45 100644 --- a/package-lock.json +++ b/package-lock.json @@ -20,6 +20,7 @@ "js-yaml": "^5.5.0", "lightningcss": "^1.33.0", "magic-string": "^1.4.5", + "markdown-it": "^15.0.3", "mri": "^1.2.0", "node-addon-api": "^8.9.2", "phaser": "^4.2.1", @@ -211,6 +212,70 @@ "js-yaml": "bin/js-yaml.js" } }, + "node_modules/@11ty/eleventy/node_modules/linkify-it": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.2.tgz", + "integrity": "sha512-ONTm2jCMAVZjgQa/Fy1kScXsuOoF5NPTsoFBdE1KVIZ2vAh/r9+Bqo+0jINCBYnavTPQZz38QzFTme79ENoN3Q==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/markdown-it" + } + ], + "license": "MIT", + "dependencies": { + "uc.micro": "^2.0.0" + } + }, + "node_modules/@11ty/eleventy/node_modules/markdown-it": { + "version": "14.3.3", + "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.3.3.tgz", + "integrity": "sha512-L//tDAkjTjJCU6pBUSBTgs3Kg4InVaZuUZog/b6V12UKhcDQ7S78877ibbCanRExwPuYP1CZD7Gd2dxSy1GXRg==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/markdown-it" + } + ], + "license": "MIT", + "dependencies": { + "argparse": "^2.0.1", + "entities": "^4.5.0", + "linkify-it": "^5.0.2", + "mdurl": "^2.0.0", + "punycode.js": "^2.3.1", + "uc.micro": "^2.1.0" + }, + "bin": { + "markdown-it": "bin/markdown-it.mjs" + } + }, + "node_modules/@11ty/eleventy/node_modules/markdown-it/node_modules/entities": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/@11ty/eleventy/node_modules/uc.micro": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-2.1.0.tgz", + "integrity": "sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==", + "license": "MIT" + }, "node_modules/@11ty/lodash-custom": { "version": "4.17.21", "resolved": "https://registry.npmjs.org/@11ty/lodash-custom/-/lodash-custom-4.17.21.tgz", @@ -3342,9 +3407,9 @@ } }, "node_modules/linkify-it": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.2.tgz", - "integrity": "sha512-ONTm2jCMAVZjgQa/Fy1kScXsuOoF5NPTsoFBdE1KVIZ2vAh/r9+Bqo+0jINCBYnavTPQZz38QzFTme79ENoN3Q==", + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-6.1.0.tgz", + "integrity": "sha512-wJ/TwpSDTLepCrQoYWYIExIKg5Zchex2Nn5yk2mFnB+6PtdkHtyLx742md9csRjjOnGkKIS/RrbY7l8D6gT9Vw==", "funding": [ { "type": "github", @@ -3357,7 +3422,7 @@ ], "license": "MIT", "dependencies": { - "uc.micro": "^2.0.0" + "uc.micro": "^3.0.0" } }, "node_modules/liquidjs": { @@ -3431,9 +3496,9 @@ } }, "node_modules/markdown-it": { - "version": "14.3.3", - "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.3.3.tgz", - "integrity": "sha512-L//tDAkjTjJCU6pBUSBTgs3Kg4InVaZuUZog/b6V12UKhcDQ7S78877ibbCanRExwPuYP1CZD7Gd2dxSy1GXRg==", + "version": "15.0.3", + "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-15.0.3.tgz", + "integrity": "sha512-+Az7Ojz3iRGu8KYMvJ6xVhvrxP3eE+vEtJX75Ow88XBpcQNV/0lGX5ZynIIBftREo4DC2jsveAMDaeltmm8QvQ==", "funding": [ { "type": "github", @@ -3446,24 +3511,40 @@ ], "license": "MIT", "dependencies": { - "argparse": "^2.0.1", - "entities": "^4.5.0", - "linkify-it": "^5.0.2", - "mdurl": "^2.0.0", + "argparse": "^3.0.3", + "entities": "^8.1.0", + "linkify-it": "^6.1.0", + "mdurl": "^2.1.0", "punycode.js": "^2.3.1", - "uc.micro": "^2.1.0" + "uc.micro": "^3.0.0" }, "bin": { "markdown-it": "bin/markdown-it.mjs" } }, + "node_modules/markdown-it/node_modules/argparse": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-3.0.4.tgz", + "integrity": "sha512-fwWK3Zq22l4XJJjx5mcBHGikIk+hJqO+32dPm0Jur7+rtG5x1scOjSfdT9ZKeWHPpsya/l0HHK4tDImBkTrtvA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/nodeca" + } + ], + "license": "PSF-2.0" + }, "node_modules/markdown-it/node_modules/entities": { - "version": "4.5.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", - "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-8.1.0.tgz", + "integrity": "sha512-kxL7msIffSuh9aaFAMD7rxAIuTRMAHMeBtgHW2yUdWw732ZNh4MehkF2gdjvtdmikkaIP9bFDDJOPlsvm7avrA==", "license": "BSD-2-Clause", "engines": { - "node": ">=0.12" + "node": ">=20.19.0" }, "funding": { "url": "https://github.com/fb55/entities?sponsor=1" @@ -3480,9 +3561,9 @@ } }, "node_modules/mdurl": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-2.0.0.tgz", - "integrity": "sha512-Lf+9+2r+Tdp5wXDXC4PcIBjTDtq4UKjCPMQhKIuzpJNW0b96kVqSwW0bT7FhRSfmAiFYgP+SCRvdrDozfh0U5w==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-2.1.0.tgz", + "integrity": "sha512-1+HBaOx0zi/dQWht8rNv9MYf9qqpqL/kxI0hXImU6Y547zM6Sni8BQibt7ifgMcYtQg41ao3Ivd6cnSM86inpg==", "license": "MIT" }, "node_modules/memorystream": { @@ -4960,9 +5041,9 @@ } }, "node_modules/uc.micro": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-2.1.0.tgz", - "integrity": "sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-3.0.0.tgz", + "integrity": "sha512-U3PppEkleoTnIfi8BozMx3yju3qc/L6SwqWo2Sw+54PX+PX0q9I+r1Um5HCmqD7n9VDX5/v3vQH/AjA6deDdtw==", "license": "MIT" }, "node_modules/unbox-primitive": { diff --git a/package.json b/package.json index ff183fe1..71ef9266 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ "description": "A community for open-source programmers and software engineers.", "main": "script.js", "dependencies": { + "markdown-it": "^15.0.3", "@11ty/eleventy": "^3.1.8", "@tailwindcss/postcss": "^4.3.4", "detect-libc": "^2.1.2", diff --git a/src/_includes/bio.njk b/src/_includes/bio.njk index f524403a..4c7632d5 100644 --- a/src/_includes/bio.njk +++ b/src/_includes/bio.njk @@ -70,7 +70,7 @@ layout: layouts/base.njk Professional Bio
"{{ bio | trim | truncate(120) }}"
+"{{ bio | markdown | striptags | trim | truncate(120) }}"
{% endif %} diff --git a/src/users/kenhorlador.yaml b/src/users/kenhorlador.yaml index 27baf2fb..c64966e2 100644 --- a/src/users/kenhorlador.yaml +++ b/src/users/kenhorlador.yaml @@ -11,14 +11,14 @@ location: Camarines Sur role: Software Engineer / UI/UX Designer / Layout Artist languages: c c++ js css3 html5 python3.82+ golang scss typescript bio: | - I'm **Ken Horlador** from Camarines Sur, Philippines. I enjoy learning programming languages and libraries/frameworks like ReactJS with GatsbyJS or NextJS. I also enjoy wireframing, developing user flows, user interface, user experience and design in general. + I'm **Ken Horlador** from Camarines Sur, Philippines. I enjoy learning programming languages and libraries/frameworks like [ReactJS](https://reactjs.org/) with [GatsbyJS](https://www.gatsbyjs.com/) or [NextJS](https://nextjs.org/). I also enjoy wireframing, developing user flows, user interface, user experience and design in general. - Currently taking Bachelor of Science in Computer Science at Camarines Sur Polytechnic Colleges. + Currently taking Bachelor of Science in Computer Science at [Camarines Sur Polytechnic Colleges](https://cspc.edu.ph/). - Former Layout Artist at The USI-Façade | The Official Student Publication of Universidad de Sta. Isabel [ 2019 - 2020 ] + Former Layout Artist at [The USI-Façade | The Official Student Publication](https://www.facebook.com/theusifacade) of [Universidad de Sta. Isabel](https://www.usi.edu.ph/) **[2019 - 2020]** - Currently working as a Layout Artist at TheSpark | The Official Student-Community Publication of Camarines Sur Polytechnic Colleges [ 2020 - Present ] + Currently working as a Layout Artist at [TheSpark | The Official Student-Community Publication](https://www.facebook.com/thesparkpub) of [Camarines Sur Polytechnic Colleges](https://cspc.edu.ph/) **[2020 - *Present*]** - Personality type: INTJ ( Introverted, Intuitive, Thinking, Judging ) + Personality type: **INTJ** (Introverted, Intuitive, Thinking, Judging) - Pronouns: He/Him/His + Pronouns: **He/Him/His**