Skip to content

Commit

Permalink
A bit more
Browse files Browse the repository at this point in the history
  • Loading branch information
sneridagh committed Mar 3, 2024
1 parent 14c63b6 commit 424381a
Show file tree
Hide file tree
Showing 5 changed files with 113 additions and 22 deletions.
56 changes: 46 additions & 10 deletions PACKAGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Plone frontend packages

## `@plone/types`

Plone types is worth to have its own entry, as it's an special development package.
It contains the Plone typings for TypeScript.
It's considered a core package, and it's the only package that the other core packages can rely on (as devDependency).

This package contains `.d.ts` typing definitions, curated by hand.
Due to the nature of this package, it does not need bundling.
It's publised "as it is", so you can import the type definitions from anywhere in your code.

## Core packages

- `@plone/registry`
Expand All @@ -9,18 +19,12 @@
### Rules

They can't depend on any other `@plone/*` package, with only one exception: `@plone/types`.
They must be published in a traditional way, bundled.
This bundle must work on both commonjs and ESM environments.

## Special development packages
They must be published and bundled in a traditional (transpiled) way.
The bundle of these packages must work on both commonjs and ESM environments.

- `@plone/types`

### Rules
## Feature packages

This package contains `.d.ts` typing definitions, curated by hand.
Due to the nature of this package, it does not need bundling.
It's publised "as it is", so you can import the type definitions from anywhere in your code.
- `@plone/contents`

## Utility packages

Expand All @@ -29,6 +33,38 @@ It's publised "as it is", so you can import the type definitions from anywhere i
- `@plone/drivers`
- `@plone/rsc`

### Rules

They can depend on core packages and other utility packages.
They must be published in a traditional way, bundled.
This bundle must work on both commonjs and ESM environments.

## Development utility packages

These are packages that are not bundled, and they are used in conjunction with Volto core or Volto projects.
They contain utilities that are useful for the development of a Volto project.
Some of them are released:

- `@plone/scripts`
- `@plone/generator-volto`

and some of them are used by the build, and separated in packages for convenience.

- `tsconfig`
- `parcel-optimizer-react-client`

## Volto add-ons packages

These are packages used by Volto core.
They are loaded always, so they are also called "core packages".
The Volto add-ons are not transpiled or bundled, they are supposed to be used and built along with a Volto project build.

- `@plone/volto-slate`

## Volto testing add-on packages

These packages are used when testing Volto core.
They contain fixtures configuring features or components that the vanila Volto core does not have by default.
Once their fixtures are loaded, they can be tested, for example, in acceptance tests.

- `@plone/volto-coresandbox`
3 changes: 3 additions & 0 deletions packages/blocks/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# `@plone/blocks`

This package contains the default blocks provided by Plone.
43 changes: 31 additions & 12 deletions packages/components/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,34 +97,52 @@ It's even possible to use TailwindCSS for styling the components in this package

### Basic

- BlockToolbar
- Button
- Checkbox
- CheckboxField
- CheckboxGroup
- Combobox
- Container
- Dialog
- Form
- GridList
- Icon
- Link
- Listbox
- ListBox
- Menu
- Modal
- NumberField
- Popover
- RadioGroup
- Select
- Switch
- Slider
- Table
- Tabs
- TagGroup
- TextField
- TextAreaField
- ToggleButton
- Toolbar
- BlockToolbar
- Tooltip

### Forms

- CheckboxField
- Form
- Meter
- NumberField
- SearchField
- Select
- TextAreaField
- TextField
- TimeField

### Widgets

- Calendar
- CheckboxField
- CheckboxGroup
- ComboBox
- DateField
- DatePicker
- DateRangePicker
- ProgressBar
- RadioGroup
- RangeCalendar
- Switch

### Viewlets

- Breadcrumbs
Expand All @@ -138,6 +156,7 @@ It's even possible to use TailwindCSS for styling the components in this package

- TextField
- TextAreaField
- Select

## Quanta icons

Expand Down
4 changes: 4 additions & 0 deletions packages/parcel-optimizer-react-client/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# `parcel-optimizer-react-client`

This package is a `parcel` plugin that prepends `use client` to any bundled file.
This is useful to mark a separation of concerns in frameworks that support React Server Components, like Next.JS.
29 changes: 29 additions & 0 deletions packages/tsconfig/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# `tsconfig`

Base configurations for TypeScript projects.

## Usage

In `package.json`:

```json
"devDependencies": {
"tsconfig": "workspace:*",
}
```

```json
{
"extends": "tsconfig/react-library.json",
"include": ["src", "src/**/*.js"],
"exclude": [
"node_modules",
"build",
"public",
"coverage",
"src/**/*.test.{js,jsx,ts,tsx}",
"src/**/*.spec.{js,jsx,ts,tsx}",
"src/**/*.stories.{js,jsx,ts,tsx}"
]
}
```

0 comments on commit 424381a

Please sign in to comment.