alineacms / alinea Goto Github PK
View Code? Open in Web Editor NEWContent management, streamlined
Home Page: https://alinea.sh
License: MIT License
Content management, streamlined
Home Page: https://alinea.sh
License: MIT License
Publishing an entry without having all published parents should not be possible
See if we can apply this:
https://github.com/microsoft/TypeScript/wiki/Performance#writing-easy-to-compile-code
Allow field data to be indexed
type({
fieldA,
fieldB
}).configure({
index(fields) {
return {
myIndex: [fields.fieldA, fields.fieldB]
}
}
})
Investigate if we can easily render a complete preview inside a shadow root
Make sure resizable Panes don't register values higher than a configurable maxWidth
Watch for content source / config source changes, we can probably use esbuilds watcher by adding all of our sources to watchFiles in a plugin
... but find out how mark (s)css imports as having side effects.
maybe:
Modal/popover with:
Add expiration time for the email token
Should probably map to an html tag? I'm not sure where the tiptap/prosemirror types stem from.
For each package check if external imports are included in (peer)dependencies, warn if not. Maybe also warn about unused dependencies.
As soon as better-sqlite3 is updated:
Needs proper styling
Needs to inline blocks
Running cli includes @alinea/core which depends on react. In non react projects we'll need to either instruct to add react and react-dom or side step the problem
And document expected errors with a link
Above file upload we can have a summary of accepted types and a direct link to create one in either a new tab (phase 1) or new modal with input field (phase 2). Link field will have to supply accepted types and a parent under which they can be created (or: parent is chosen in creating dialog which will keep the interface cleaner).
Since we're generating code we need to watch for name clashes, off the top of my head:
The sql.js-fts5 wasm file is about 435kb gzipped. Stripping unnecessary features we should be able to get it close to 220kb.
Starting with https://github.com/kbumsik/sqlite-wasm as a template and the config below. That package is focused on the browser however so we'll need to enable nodejs loading of the library in emscripten.
EMCC_SQLITE_FLAGS = \
-DSQLITE_ENABLE_FTS5 \
-DSQLITE_ENABLE_JSON1 \
-DSQLITE_OMIT_LOAD_EXTENSION \
-DSQLITE_DISABLE_LFS \
-DLONGDOUBLE_TYPE=double \
-DSQLITE_THREADSAFE=0 \
-DSQLITE_DQS=0\
-DSQLITE_DEFAULT_MEMSTATUS=0 \
-DSQLITE_OMIT_DEPRECATED \
-DSQLITE_MAX_EXPR_DEPTH=0 \
-DSQLITE_OMIT_SHARED_CACHE \
-DSQLITE_OMIT_PROGRESS_CALLBACK \
-DSQLITE_LIKE_DOESNT_MATCH_BLOBS\
-DSQLITE_DEFAULT_FOREIGN_KEYS=1 \
-DSQLITE_TEMP_STORE=2\
-DSQLITE_OMIT_DECLTYPE \
-DSQLITE_OS_OTHER=1 \
-DHAVE_LOCALTIME_R \
-DNDEBUG=1 \
$(SQLITE_OWN_OPTIMIZATIONS)
SQLITE_OWN_OPTIMIZATIONS = \
-DSQLITE_OMIT_ANALYZE \
-DSQLITE_OMIT_ATTACH \
-DSQLITE_OMIT_AUTHORIZATION \
-DSQLITE_OMIT_AUTOINCREMENT \
-DSQLITE_OMIT_AUTOMATIC_INDEX \
-DSQLITE_OMIT_AUTOVACUUM \
-DSQLITE_OMIT_BLOB_LITERAL \
-DSQLITE_OMIT_CASE_SENSITIVE_LIKE_PRAGMA \
-DSQLITE_OMIT_CHECK \
-DSQLITE_OMIT_COMPILEOPTION_DIAGS \
-DSQLITE_OMIT_COMPLETE \
-DSQLITE_OMIT_COMPOUND_SELECT \
-DSQLITE_OMIT_DESERIALIZE \
-DSQLITE_OMIT_DECLTYPE \
-DSQLITE_OMIT_EXPLAIN \
-DSQLITE_OMIT_FLAG_PRAGMAS \
-DSQLITE_OMIT_FOREIGN_KEY \
-DSQLITE_OMIT_GET_TABLE \
-DSQLITE_OMIT_INTEGRITY_CHECK \
-DSQLITE_OMIT_INTROSPECTION_PRAGMAS \
-DSQLITE_OMIT_LOCALTIME \
-DSQLITE_OMIT_LOOKASIDE \
-DSQLITE_OMIT_MEMORYDB \
-DSQLITE_OMIT_PAGER_PRAGMAS \
-DSQLITE_OMIT_QUICKBALANCE \
-DSQLITE_OMIT_REINDEX \
-DSQLITE_OMIT_AUTORESET \
-DSQLITE_OMIT_SCHEMA_PRAGMAS \
-DSQLITE_OMIT_SCHEMA_VERSION_PRAGMAS \
-DSQLITE_OMIT_TCL_VARIABLE \
-DSQLITE_OMIT_TEMPDB \
-DSQLITE_OMIT_TRACE \
-DSQLITE_OMIT_TRUNCATE_OPTIMIZATION \
-DSQLITE_OMIT_UTF16 \
-DSQLITE_OMIT_VACUUM \
-DSQLITE_OMIT_VIEW \
-DSQLITE_OMIT_WAL \
-DSQLITE_OMIT_XFER_OPT \
-DSQLITE_UNTESTABLE
Warn on init that we need version 18. Or fix compatibility with react 17 (eliminate useId usage).
It would be nice to have a yaml loader which can format rich text as markdown, embedding inner blocks as html:
id: ...
title: My entry
body: |
# Heading
Some text
<CodeBlock code="..." />
More text
When executing user code we'll try to force esm but should find a way to run with node resolution to accomodate third party libraries.
Tried:
Considered:
To try:
?
Serve a local admin panel based on the config file
Using the cli currently assumes a node environment, but in an environment like stackblitz.com we have all the node apis but no native node libs. Ideally we can detect and use sql.js instead.
Figure out a way to track whether a publish is online (and successful).
Ideas:
When an entry is created, but never published, then discarded we need to redirect to its parent.
Publish them privately to github first? @alineacms/...
For example: alt, description, target etc
See
alinea/packages/website/alinea.config.tsx
Lines 60 to 71 in 54f269f
Ideally we can ship without having to tweak next.config.js when these are fixed
Resizing images fails in next production build:
This could be useful too:
Using esbuild on nextjs sources, which forces jsx to "preserve" has the following issue
Generate a la prisma/client so on postinstall, manually with alinea generate
and while watching file system with alinea generate --watch
Step 1: find schema
{"alinea": {"schema": "./my-schema.ts"}}
)Step 2: create/update folder
{"alinea": {"package": "./my-dir"}}
)Step 3: generate
export * from '../src/schema'
export type Page = EntryOf<typeof schema>
export const Home: Collection<Extract<Page, {type: 'Home'}>>
export type Home = DataOf<typeof Home>
Step 4: index
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.