This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#![cfg_attr( | |
all(not(debug_assertions), target_os = "windows"), | |
windows_subsystem = "windows" | |
)] | |
use reqwest; | |
use std::io::Read; | |
#[tauri::command] | |
fn get_data(address: String, endpoint: String) -> String { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
////////////////////////////////////////////////////////////////////////////////// | |
// Make call to Rust backend to query the Pi's flask server for sensor values // | |
////////////////////////////////////////////////////////////////////////////////// | |
callBackend() { | |
let i = localStorage.getItem("pi_address"); | |
if (i == "") { | |
console.log("[!] No sensor address available -> Update device info using the SideDash tab... [!]"); | |
this.setAddressModalVisible(true); | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download appimagetool | |
wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-aarch64.AppImage | |
# Make it executable | |
chmod a+x appimagetool-aarch64.AppImage | |
# Run the tool, specifying the AppDir that the `yarn tauri build` command generates | |
./appimagetool-aarch64.AppImage <project-directory>/src-tauri/target/release/bundle/appimage/<project-name>.AppDir |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"context" | |
"fmt" | |
) | |
// App struct | |
type App struct { | |
ctx context.Context |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"embed" | |
"github.com/wailsapp/wails/v2" | |
"github.com/wailsapp/wails/v2/pkg/options/mac" | |
) | |
//go:embed all:frontend/dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { | |
MDBCard, | |
MDBCardImage, | |
MDBCardBody, | |
MDBCardTitle, | |
MDBCardText, | |
MDBRow, | |
MDBCol | |
} from 'mdb-react-ui-kit'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useState } from 'react'; | |
import './App.css'; | |
import { Greet } from "../wailsjs/go/main/App"; | |
import TopNav from './TopNav'; | |
import CardGroup from './CardGroup'; | |
function App() { | |
const [resultText, setResultText] = useState("Please enter your name below 👇"); | |
const [name, setName] = useState(''); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { useColorScheme } from 'react-native'; | |
import { MD3LightTheme, MD3DarkTheme, Provider as PaperProvider } from 'react-native-paper'; | |
import { AppNavigator } from './components/MainNavigator'; | |
import { StatusBar } from 'expo-status-bar'; | |
const MaterialLightTheme = { | |
...MD3LightTheme, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "example-app", | |
"version": "1.0.0", | |
"main": "node_modules/expo/AppEntry.js", | |
"scripts": { | |
"start": "expo start", | |
"android": "expo start --android", | |
"ios": "expo start --ios", | |
"web": "expo start --web" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import { ImageBackground, StyleSheet, View } from 'react-native'; | |
import { Card, Title, Paragraph } from 'react-native-paper'; | |
export default class ImageCard extends Component { | |
constructor(props) { | |
super(props); | |
} |
OlderNewer