GithubHelp home page GithubHelp logo

phiresky / blog Goto Github PK

View Code? Open in Web Editor NEW
338.0 12.0 56.0 123.31 MB

Source code of my personal blog

Home Page: https://phiresky.github.io/blog/

License: Other

JavaScript 1.14% TypeScript 57.21% Shell 0.31% SCSS 39.71% CSS 1.63%

blog's Introduction

Source code of my blog

https://phiresky.github.io/blog/

The posts are written in Markdown that is parsed by Pandoc, with the Pandoc AST rendered with React. This is done so the React renderer can have a few custom components, especially code blocks with specific tags are interpreted as e.g. interactive demos or charts. All the React stuff is rendered server-side with next.js to static HTML files. So most of the blog should work without JS.

It also generates an RSS feed for people that are into that.

Run yarn posts to generate the posts, then yarn dev for the hot-reloading dev server (navigate to http://localhost:3000/blog/ )

Run yarn build to run all the build steps, or yarn commit to commit a new blog version ready for pushing.

blog's People

Contributors

phiresky avatar pieterdd avatar stephensauceda avatar tscanlin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

blog's Issues

Detailed install steps. Could not load httpvfs config: 404 Not Found for SQLite file

I've documented install commands for compatibility issues:
https://model.earth/data-pipeline/timelines/sqlite/phiresky/

I included steps from issue 11
But ultimately I still had to run npm install

The last remaining item to resolve is loading the SQLite file. Any ideas?
Error: Could not load httpvfs config: 404 Not Found

blog-sqlite-error

Note: You won't see the blog list locally here: http://localhost:3000
Go here instead: http://localhost:3000/blog/

Is the inclusion of "blog" in the site path a possible clue for why the SQLite file is not found?

SQLite memory mapping comment

Hi, not sure if this is the right place for comments. I notice you mention:

Uses memory mapping instead of read/write calls when db is < mmap_size.

Maybe I misread it, but I took this to mean "when total database size > mmap_size, the memory mapping would not be used at all". I later found out the memory mapping will still be used, but only for the starting bytes of the database up to mmap_size, so it can still give some performance benefit. It also might be worth noting a warning from the SQLite documentation: if a read fails (e.g. USB stick pulled out of drive), then you'll get a signal or crash rather than a graceful read error! But that's OK for some applications.

Compatibility errors with React libraries

Hello, I found your blog project very interesting, and I tried to replicate it in my local environment, but it is showing some compatibility errors with React libraries.

Below is the error that is happening.

npm WARN using --force Recommended protections disabled.
npm WARN ERESOLVE overriding peer dependency
npm WARN While resolving: [email protected]
npm WARN Found: [email protected]
npm WARN node_modules/react
npm WARN   react@"^18.2.0" from the root project
npm WARN   32 more (@emotion/react, ...)
npm WARN 
npm WARN Could not resolve dependency:
npm WARN peer react@"^15.3.2 || ^16.0.0" from [email protected]
npm WARN node_modules/react-katex
npm WARN   react-katex@"^2.0.2" from the root project
npm WARN 
npm WARN Conflicting peer dependency: [email protected]
npm WARN node_modules/react
npm WARN   peer react@"^15.3.2 || ^16.0.0" from [email protected]
npm WARN   node_modules/react-katex
npm WARN     react-katex@"^2.0.2" from the root project

➜  ~ node -v 
v18.13.0
➜  ~ npm -v 
9.6.5
➜  ~ yarn -v 
1.22.17
➜  ~ 

Failing to build from example

Hi

I'm a complete typescript novice and was trying to rebuild a working blog from this repo to explore using the sqlite components.

After installing TypeScript (npm install typescript) I tried the yarn build command but it failed on:

client/pages/index.tsx:3:21 - error TS2307: Cannot find module '../../posts-built/summary.json' or its corresponding type declarations.

Chasing dow the errors, I created an empty posts-built/summary.json file, then one with the contents {"posts":[]}, but it still wants more; does a schema, or some such, for that object need defining somewhere to be able to run the build?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.