Compare commits

...

12 Commits

Author SHA1 Message Date
Ola Rubaj
bfbf0f5304 [site/blog][s]: content adjustments 2023-10-12 11:08:38 +02:00
Ola Rubaj
0db2055da3 [site/blog][xs]: add emoji to title 2023-10-11 17:42:30 +02:00
Ola Rubaj
d96d5555a0 [site/blog][s]: markdowndb launch post 2023-10-11 17:41:24 +02:00
João Demenech
6b3afa878b Merge pull request #1035 from datopian/changeset-release/main
Version Packages
2023-10-10 20:48:41 -03:00
github-actions[bot]
c9a39ec421 Version Packages 2023-10-10 23:48:00 +00:00
leonardo.farias
63ad514f9e Merge branch 'main' of https://github.com/datopian/portaljs 2023-10-10 20:44:21 -03:00
leonardo.farias
e4624c35cb adding version bump to remark-wiki-link package 2023-10-10 20:44:00 -03:00
Anuar Ustayev (aka Anu)
975aaed743 Merge pull request #1034 from datopian/portal-cus
Add Link to portaljs cloud site
2023-10-10 19:03:20 +02:00
steveoni
b8b6dd662d [Hero][s]: change button style for portal cloud cta 2023-10-10 16:00:36 +01:00
steveoni
98db406793 [Navitem][s]: add insine style condition 2023-10-10 14:39:43 +01:00
steveoni
9ea045d16a [Navitem][s]: add portaljs.com to navbar 2023-10-10 14:15:39 +01:00
steveoni
6acef2be56 [Hero.tsx][s]: remove newsletter form and Portaljs cloud cta 2023-10-10 14:00:47 +01:00
7 changed files with 165 additions and 8 deletions

View File

@@ -1,5 +1,11 @@
# @portaljs/remark-wiki-link
## 1.1.1
### Patch Changes
- [`e4624c35`](https://github.com/datopian/portaljs/commit/e4624c35cb559c7eb17efe1f9def9d8a0b18a859) - Fix links with accents resolving to empty links
## 1.1.0
### Minor Changes

View File

@@ -1,6 +1,6 @@
{
"name": "@portaljs/remark-wiki-link",
"version": "1.1.0",
"version": "1.1.1",
"description": "Parse and render wiki-style links in markdown especially Obsidian style links.",
"repository": {
"type": "git",

View File

@@ -30,16 +30,13 @@ export function Hero() {
</ButtonLink>
<ButtonLink
style="secondary"
style="primary"
className="mt-8 ml-3"
href="https://github.com/datopian/portaljs"
href="https://portaljs.com/"
>
View on GitHub
PortalJS Cloud
</ButtonLink>
<div className="md:max-w-md mx-auto lg:mx-0 ">
<NewsletterForm />
</div>
<p className="my-10 text-l tracking-wide">
<span>A project of</span>
<a

View File

@@ -29,7 +29,7 @@ export default function NavItem({ item }) {
onMouseLeave={closeDropdown}
target={item.target || '_self'}
onClick={() => setshowDropdown(!showDropdown)}
className="text-slate-600 dark:text-slate-400 inline-flex items-center mr-2 px-1 pt-1 text-sm font-medium hover:text-slate-500"
className={`${item.name.includes("Cloud") ? "text-blue-600 dark:text-blue-400" : "text-slate-600 dark:text-slate-400"} inline-flex items-center mr-2 px-1 pt-1 text-sm font-medium hover:text-slate-500`}
>
{item.name}
</Link>

Binary file not shown.

After

Width:  |  Height:  |  Size: 247 KiB

View File

@@ -0,0 +1,148 @@
---
title: 'Announcing MarkdownDB: an open source tool to create an SQL API to your markdown files! 🚀'
description: MarkdownDB - an open source library to transform markdown content into sql-queryable data. Build rich markdown-powered sites easily and reliably. New dedicated website at markdowndb.com
date: 2023-10-11
authors: ['Ola Rubaj']
---
Hello, dear readers!
We're excited to announce the official launch of MarkdownDB, an open source library to transform markdown content into sql-queryable data. Get a rich SQL API to your markdown files in seconds and build rich markdown-powered sites easily and reliably.
We've also created a new dedicated website:
https://markdowndb.com/
## 🔍 What is MarkdownDB?
MarkdownDB transforms your Markdown content into a queryable, lightweight SQLite database. Imagine being able to treat your collection of markdown files like entries in a database! Ever thought about fetching documents with specific tags or created in the past week? Or, say, pulling up all tasks across documents marked with the "⏭️" emoji? With MarkdownDB, all of this (and more) is not just possible, but a breeze.
## 🌟 Features
- Rich metadata extracted including frontmatter, links and more.
- Lightweight and fast indexing 1000s of files in seconds.
- Open source and extensible via plugin system.
## 🚀 How it works
### You have a folder of markdown content
For example, your blog posts. Each file can have a YAML frontmatter header with metadata like title, date, tags, etc.
```md
---
title: My first blog post
date: 2021-01-01
tags: [a, b, c]
author: John Doe
---
# My first blog post
This is my first blog post.
I'm using MarkdownDB to manage my blog posts.
```
### Index the files with MarkdownDB
Use the npm `mddb` package to index Markdown files into an SQLite database. This will create a `markdown.db` file in the current directory.
```bash
# npx mddb <path-to-folder-with-your-md-files>
npx mddb ./blog
```
### Query your files with SQL...
E.g. get all the files with with tag `a`.
```sql
SELECT files.*
FROM files
INNER JOIN file_tags ON files._id = file_tags.file
WHERE file_tags.tag = 'a'
```
### ...or using MarkdownDB Node.js API in a framework of your choice!
Use our Node API to query your data for your blog, wiki, docs, digital garden, or anything you want!
E.g. here is an example of a Next.js page:
```js
// @/pages/blog/index.js
import React from 'react';
import clientPromise from '@/lib/mddb.mjs';
export default function Blog({ blogs }) {
return (
<div>
<h1>Blog</h1>
<ul>
{blogs.map((blog) => (
<li key={blog.id}>
<a href={blog.url_path}>{blog.title}</a>
</li>
))}
</ul>
</div>
);
}
export const getStaticProps = async () => {
const mddb = await clientPromise;
// get all files that are not marked as draft in the frontmatter
const blogFiles = await mddb.getFiles({
frontmatter: {
draft: false,
},
});
const blogsList = blogFiles.map(({ metadata, url_path }) => ({
...metadata,
url_path,
}));
return {
props: {
blogs: blogsList,
},
};
};
```
And the imported library with MarkdownDB database connection:
```js
// @/lib/mddb.mjs
import { MarkdownDB } from 'mddb';
const dbPath = 'markdown.db';
const client = new MarkdownDB({
client: 'sqlite3',
connection: {
filename: dbPath,
},
});
const clientPromise = client.init();
export default clientPromise;
```
### Build your blog, wiki, docs, digital garden, or anything you want
And share it with the world!
![[markdowbdb-launch-site-example.png]]
👉 [Read the full tutorial](https://markdowndb.com/blog/basic-tutorial)
---
Find out more on our new official website: https://markdowndb.com/
Check out the source on GitHub: https://github.com/datopian/markdowndb
— Ola Rubaj, Developer at Datopian

View File

@@ -31,6 +31,12 @@ const config = {
href: 'https://storybook.portaljs.org',
target: '_blank',
},
{
name: 'Cloud ☁️',
href: 'https://portaljs.com/',
target: '_blank',
style: 'text-blue-600 dark:text-blue-400'
},
// { name: "DL Demo", href: "/data-literate/demo" },
// { name: "Excel Viewer", href: "/excel-viewer" },
],