Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added custom theme tutorial docs #1393

Merged
merged 1 commit into from
Jan 17, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions website/docs/getting-started/custom-theme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
id: custom-theme
title: Custom theme
sidebar_position: 4
---

We've made hundreds of custom components across dozens of projects, including complete custom themes. Most of them began as source forks of `uniforms-unstyled` - one simply copies the source and imports `./some/project/path/uniforms-custom-theme-with-a-cool-name`.

For the purposes of this tutorial we will be using `uniforms-custom-theme` as our custom theme name.

## Copy theme source

Copy source of `uniforms-unstyled` package from uniforms repository, or any other provided theme that you would like to extend, and put it somewhere inside your project, e.g. `./uniforms-custom-theme`.

Now you can start making changes to your own custom theme!

## Import newly created theme

Instead of importing themes from `node_modules` (original uniforms theme packages), simply import theme from your local path.

That's all!

## Referenced issues and pull requests

[#433](https://github.com/vazco/uniforms/issues/433) [#609](https://github.com/vazco/uniforms/issues/609#issuecomment-545079686) [#612](https://github.com/vazco/uniforms/pull/612#issuecomment-545643935)
Loading