1
0
mirror of https://github.com/oceanprotocol/docs.git synced 2024-11-26 19:49:26 +01:00

test syntax highlighting

This commit is contained in:
Matthias Kretschmann 2018-11-09 12:35:54 +01:00
parent a49dd4e104
commit 5524cbbc35
Signed by: m
GPG Key ID: 606EEEF3C479A91F
3 changed files with 41 additions and 11 deletions

View File

@ -179,13 +179,15 @@ Inline `code` has `back-ticks around` it.
Blocks of code are either fenced by lines with three back-ticks, or are indented with four spaces. I recommend only using the fenced code blocks -- they're easier and only they support syntax highlighting. Blocks of code are either fenced by lines with three back-ticks, or are indented with four spaces. I recommend only using the fenced code blocks -- they're easier and only they support syntax highlighting.
<pre><code>```js <pre><code>```js
var s = "JavaScript syntax highlighting"; ...
alert(s);
``` ```
```python ```python
s = "Python syntax highlighting" ...
print s ```
```java
...
``` ```
``` ```
@ -194,14 +196,42 @@ But let's throw in a &lt;b&gt;tag&lt;/b&gt;.
``` ```
</code></pre> </code></pre>
```javascript ```js
var s = "JavaScript syntax highlighting"; const { Ocean, Logger } = require('@oceanprotocol/squid');
alert(s);
(async () => {
const ocean = await Ocean.getInstance({
nodeUri: 'http://localhost:8545'
})
const accounts = await ocean.getAccounts()
Logger.log(JSON.stringify(accounts, null, 2))
})()
``` ```
```python ```python
s = "Python syntax highlighting" from squid_py.ocean_contracts import OceanContractsWrapper
print s
ocean = OceanContractsWrapper(host='http://localhost', port=8545, config_path='config.ini')
ocean.init_contracts()
```
```java
package com.oceanprotocol.squid.core;
import com.oceanprotocol.squid.models.AbstractModel;
import java.io.IOException;
public interface FromJsonToModel {
static AbstractModel convertToModel(String json) throws IOException {
throw new UnsupportedOperationException();
};
}
``` ```
``` ```

View File

@ -18,7 +18,7 @@
.headerLogo, .headerLogo,
.headerTitle, .headerTitle,
.headerDescription { .headerDescription {
animation: fadeInUp .8s ease-out backwards; animation: fadeInUp .8s backwards;
} }
.headerLogo { .headerLogo {

View File

@ -15,7 +15,7 @@
.section { .section {
margin-top: $spacer; margin-top: $spacer;
animation: fadeInUp .8s ease-out backwards; animation: fadeInUp .8s backwards;
&:before { display: none; } &:before { display: none; }