diff --git a/docs/faq.md b/docs/faq.md new file mode 100644 index 000000000..1dc01a1a2 --- /dev/null +++ b/docs/faq.md @@ -0,0 +1,54 @@ +# FAQ + +Frequently asked questions about Rebar. + +## Where do I put my mods? + +You put them inside of the `resources` folder, and load it like a normal [alt:V Resource](https://docs.altv.mp/articles/resources.html). + +## None of my changes are saving when I modify files? + +Be sure that you are only modifying files inside of the `src` directory. + +## Are FiveM scripts compatible? + +No, we use TypeScript in this framework and furthermore it is written for [https://altv.mp](https://altv.mp) client. + +## Can I use my own frontend framework? + +No, you will have to do a lot of changes to get any other framework to work correctly. + +It is not recommended, and to keep all plugins compatible we use Vue 3 and the same CSS framework across all plugins. + +## Can I use my own CSS? + +Sure, but it is recommended to use `Tailwind` to keep everything compatible across all plugins. + +## Can I use my own database? + +No, it is highly recommended to stick to MongoDB and to lower the complexity for everyone using your plugins. + +To run your own database you will need to write it as a plugin and use it exclusively. + +Doing so may limit your ability to load plugins from other users. + +## Do I need to buy a server? + +Only buy a server when you're ready for your server to go live. + +Otherwise, stick to local testing and allowing others to join locally. + +## How can I speed up development time? + +There are a number of ways to do this, but here are some recommended approaches. + +1. Disable any third-party plugins +2. Disable any MLOs that need to be loaded + +Doing both of these will increase load time, and allow you to focus on writing your plugin. + +## Can I sell plugins? + +Absolutely, however Rebar does not provide any resources to secure your code. You are fully responsible for updating your plugin as well as maintaining compatability with future updates. + +_Keep in mind there is no way to properly secure code._ diff --git a/docs/plugins/what-is-a-plugin.md b/docs/plugins/what-is-a-plugin.md index 0b34957aa..65de10638 100644 --- a/docs/plugins/what-is-a-plugin.md +++ b/docs/plugins/what-is-a-plugin.md @@ -10,6 +10,28 @@ A plugin can be seen as code that is meant to work with the Rebar Framework. Plugins can be found in the `src/plugins` directory, and each plugin should have a unique folder name. +## Example Plugin Structure + +``` +├───main +│ ├───client +│ ├───server +│ ├───shared +│ └───translate +└───plugins + └───your-plugin + ├───client + │ └───index.ts + ├───server + │ └───index.ts + ├───translate + │ └───index.ts + └───webview + └───MyCustomPage.vue +``` + +See [create a plugin](./create.md) for more information. + ## Disabling Plugins If you wish to disable a plugin simply add a `!` before the folder name. diff --git a/docs/webview/what-is-a-webview.md b/docs/webview/what-is-a-webview.md index a92363be5..66577cd44 100644 --- a/docs/webview/what-is-a-webview.md +++ b/docs/webview/what-is-a-webview.md @@ -31,3 +31,11 @@ Examples: `HUD`, `Cash`, `Ammunition Count` A persistent page is a type of page that will always be shown regardless of what is being shown on screen. Examples: `Website Watermark`, `Logo` + +## What CSS is Available? + +Currently Rebar is shipped with [TailwindCSS](https://tailwindcss.com/) to quickly build out interfaces quickly. + +It is **highly recommended** to install the [Tailwind CSS IntelliSense Extension](https://marketplace.visualstudio.com/items?itemName=bradlc.vscode-tailwindcss) when working with `css`. + +You can simply hit `CTRL + SPACE` to bring up auto-fill while browsing different `CSS` classes.