<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Math17</title>
    <description>The latest articles on DEV Community by Math17 (@math1987).</description>
    <link>https://dev.to/math1987</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F804178%2Fe80d0406-3894-4437-aa02-7316e0896a65.png</url>
      <title>DEV Community: Math17</title>
      <link>https://dev.to/math1987</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/math1987"/>
    <language>en</language>
    <item>
      <title>Run Unity web project with Angular</title>
      <dc:creator>Math17</dc:creator>
      <pubDate>Tue, 15 Feb 2022 09:48:25 +0000</pubDate>
      <link>https://dev.to/math1987/run-unity-web-project-with-angular-kf</link>
      <guid>https://dev.to/math1987/run-unity-web-project-with-angular-kf</guid>
      <description>&lt;p&gt;Hi, &lt;br&gt;
Here a way to run a Unity project with Angular.&lt;br&gt;
(with hardcore method!)&lt;/p&gt;

&lt;p&gt;1 - Unity settings:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;go on &lt;em&gt;edit &amp;gt; Project Settings &amp;gt; Player&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;choose the webGL tab (install the module if you don't have it)&lt;/li&gt;
&lt;li&gt;in &lt;em&gt;Resolution and Presentation&lt;/em&gt; set to "minimal"&lt;/li&gt;
&lt;li&gt;in &lt;em&gt;Publish Settings&lt;/em&gt; set &lt;em&gt;Compression Format&lt;/em&gt; to "Disabled"&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;2 - Build to your Angular assets directory&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;go on &lt;em&gt;file &amp;gt; Build Settings&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;choose the webGL platform&lt;/li&gt;
&lt;li&gt;click on &lt;em&gt;build&lt;/em&gt; and set the path to your Angular assets directory&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;3 - implement it on Angular&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;add a script src in the angular index.html (or where you want):
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;script src="/assets/yourProjectName/Build/yourProjectName.loader.js"&amp;gt;&amp;lt;/script&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;add a canvas with the id "unity-canvas" like so:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;canvas id="unity-canvas" width=960 height=600 style="width: 960px; height: 600px; background: #231F20"&amp;gt;&amp;lt;/canvas&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;wright the code below in the ts component you want to use in the ngOnInit for example:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ngOnInit() {
        //@ts-ignore
        createUnityInstance(document.querySelector("#unity-canvas"), {
          dataUrl: "/assets/yourProjectName/Build/yourProjectName.data",
          frameworkUrl: "/assets/yourProjectName/Build/yourProjectName.framework.js",
          codeUrl: "/assets/yourProjectName/Build/yourProjectName.wasm",
          streamingAssetsUrl: "StreamingAssets",
          companyName: "YourCompagny",
          productName: "yourProjectName",
          productVersion: "1.0"
        });
  } 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Done!&lt;br&gt;
Now you just have to build your project after updates from unity in the angular assets path and it should be all to use it on your project. &lt;br&gt;
For production you can delete the unless &lt;em&gt;index.html&lt;/em&gt; file generated in the &lt;em&gt;assets/yourProjectName&lt;/em&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Angular Library for Solana Wallets</title>
      <dc:creator>Math17</dc:creator>
      <pubDate>Wed, 26 Jan 2022 20:13:27 +0000</pubDate>
      <link>https://dev.to/math1987/angular-library-for-solana-wallets-14h4</link>
      <guid>https://dev.to/math1987/angular-library-for-solana-wallets-14h4</guid>
      <description>&lt;p&gt;Here is a simple Angular Library on NPM for using  Solana Wallets in your projects (actualy working with Phantom).&lt;br&gt;
&lt;a href="https://www.npmjs.com/package/angular-sol-wallets"&gt;https://www.npmjs.com/package/angular-sol-wallets&lt;/a&gt;&lt;/p&gt;

</description>
      <category>angular</category>
      <category>solana</category>
      <category>wallet</category>
      <category>npm</category>
    </item>
  </channel>
</rss>
