This commit is contained in:
Saifeddine ALOUI 2023-08-21 22:07:24 +02:00
parent fa7f180cb7
commit 4786cfc5a9

View File

@ -5,19 +5,19 @@
<button @click="execute">Execute</button>
<pre v-if="result">{{ result }}</pre>
</div>
</template>
</template>
<script>
import * as IPython from 'jupyter';
<script>
import * as IPython from 'jupyter';
export default {
data() {
export default {
data() {
return {
input: '',
result: '',
};
},
mounted() {
},
mounted() {
const widget = this.$refs.console;
if (widget) {
// Initialize the IPython console with the existing DOM node.
@ -32,8 +32,8 @@
this.execute();
});
}
},
methods: {
},
methods: {
execute() {
const widget = this.$refs.console;
const code = this.input;
@ -48,6 +48,6 @@
}
});
},
},
};
</script>
},
};
</script>