Skip to content

Commit

Permalink
update: readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrii Afanasiev committed Oct 19, 2017
1 parent 0357350 commit e270a67
Showing 1 changed file with 34 additions and 3 deletions.
37 changes: 34 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,46 @@ Dou to bad sync with composer there are some steps
4. Enable extension with name ```PHPBB Code Highlight```
5. [Optional] Navigate to the ACP ```Extensions -> PPHPBB Code Highlight -> Settings``` and setup list of languages and theme.

###### NOTE
Enabling of all languages will cause performance issues on clients side, because each langauge is loading as separate JS.
So, if You are still needed to have all languages, then it will be nice to have:
1. HTTP2 on server
2. Static-Domain
3. CDN

## How to use in posts
To highlight code in post use new PHPBB tag [syntax]:
```ini
[syntax=cpp]
#include <tuple>

std::tuple<int, bool, float> foo()
{
return std::make_tuple(128, true, 1.5f);
}

int main()
{
std::tuple<int, bool, float> result = foo();
int value = std::get<0>(result);
int obj1;
bool obj2;
float obj3;
std::tie(obj1, obj2, obj3) = foo();
}
[/syntax]
```

## Links
- [PHPBB Dev Docs](https://area51.phpbb.com/docs/dev/)
- [HighlightJS](https://highlightjs.org/)
- [Currently Used Here](https://forum.cryengine.com/)
- [PHPBB Events list](https://wiki.phpbb.com/Event_List)

## Help needed
1. Advise how to proper store dependency from [HighlightJS repo](https://github.com/isagalaev/highlight.js)
2. Advise how to wrap PHPBB extension with composer
## TODO
1. Proper store dependency from [HighlightJS repo](https://github.com/isagalaev/highlight.js)
2. Wrap PHPBB extension with composer
3. Write tests

## Thank You
Big thanks for community

0 comments on commit e270a67

Please sign in to comment.